Ticket #3281 (closed defect: fixed)

Opened 3 years ago

Last modified 3 years ago

[PATCH] Fix memory leak in DXF writer

Reported by: rouault Owned by: warmerdam
Priority: normal Milestone: 1.7.0
Component: OGR_SF Version: unspecified
Severity: normal Keywords: DXF
Cc:

Description

ogr2ogr -f DXF out.dxf assorted.dxf shows memory leaks.

One fix is obvious (missing CSLDestroy()). The other one is less. I propose to fix it by deleting the poTool object returned by oSM.GetPart?(0), but I'm not clear if that matches the intended life cycle of this object. I suppose this is somewhat correct though as in MITAB's ITABFeaturePen::SetPenFromStyleString?() it looks similar.

Attachments

ogrdxfwriterlayer.cpp.patch Download (0.9 KB) - added by rouault 3 years ago.

Change History

Changed 3 years ago by rouault

Changed 3 years ago by warmerdam

  • status changed from new to closed
  • resolution set to fixed
  • component changed from OGR_SRS to OGR_SF

I agree, fixes applied in trunk (r18298).

Note: See TracTickets for help on using tickets.