Opened 17 years ago

Closed 17 years ago

#2003 closed defect (fixed)

FeatureDefn may disappear underneath the bindings

Reported by: Ari Jolma Owned by: Ari Jolma
Priority: normal Milestone:
Component: SWIG (all bindings) Version: unspecified
Severity: normal Keywords:
Cc:

Description

use Geo::GDAL;
$d = Geo::OGR::FeatureDefn->new();
$f = Geo::OGR::Feature->new($d);

causes a segfault. The reason is that FD is destroyed twice. F increases the ref count of FD when it is created and decreases when it is destroyed. In this case the decreasing leads to FD being destroyed. The bindings do not know about this.

The possible solution is to have the bindings reference the FD also. I'm going to try this but let's have a ticket anyway.

Change History (1)

comment:1 by Ari Jolma, 17 years ago

Resolution: fixed
Status: newclosed

Fixed in r12843.

Note: See TracTickets for help on using tickets.