Uploaded image for project: 'Data Management'
  1. Data Management
  2. DM-4408

HSC backport: fix memory leak in afw:geom:polygon

    Details

    • Type: Bug
    • Status: Done
    • Resolution: Done
    • Fix Version/s: None
    • Component/s: afw
    • Labels:
      None
    • Templates:
    • Story Points:
      0.5
    • Sprint:
      Science Pipelines DM-W16-3
    • Team:
      Data Release Production

      Description

      This is a backport of a bug fix that got included as part of HSC-1311. It is not related to that issue in particular, so is being ported here as an isolated bug fix.

      Original commit message:
      pprice@tiger-sumire:/tigress/pprice/hsc-1311/afw (tickets/HSC-1311=) $ git sub
      commit 55ad42d37fd1346f8ebc11e4077366dff4eaa87b
      Author: Paul Price <price@astro.princeton.edu>
      Date: Wed Oct 21 10:59:56 2015 -0400

      imageLib: import polygonLib to prevent memory leak

      When doing "exposure.getInfo().getValidPolygon()", was getting:

      swig/python detected a memory leak of type 'boost::shared_ptr< lsst::afw::geom::polygon::Polygon > *', no destructor found.

      This was due to the polygonLib not being imported in imageLib.
      Using polygonLib in imageLib then requires adding polygon.h to all
      the swig interface files that use imageLib.i.

      examples/testSpatialCellLib.i | 1 +
      python/lsst/afw/cameraGeom/cameraGeomLib.i | 1 +
      python/lsst/afw/detection/detectionLib.i | 1 +
      python/lsst/afw/display/displayLib.i | 1 +
      python/lsst/afw/geom/polygon/Polygon.i | 1 +
      python/lsst/afw/image/imageLib.i | 2 ++
      python/lsst/afw/math/detail/detailLib.i | 1 +
      python/lsst/afw/math/mathLib.i | 1 +
      8 files changed, 9 insertions

        Attachments

          Activity

            People

            • Assignee:
              lauren Lauren MacArthur
              Reporter:
              lauren Lauren MacArthur
              Reviewers:
              Paul Price
              Watchers:
              Lauren MacArthur, Paul Price
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:

                Summary Panel