Thanks to python-dbg, it was found that self->ob_type->tp_free((PyObject*)self); also free the value of the pointer to the protobuf object, which means that the delete could use an incorrect address.
This fixes some cases where imposm-parser was stuck somewhere in the python library when reading PBF files.
The patch was tested by running a loop of "python imposm/parser/pbf/multiproc.py ", which failed before the patch, and no longer fails with the patch.
Thanks to python-dbg, it was found that self->ob_type->tp_free((PyObject*)self); also free the value of the pointer to the protobuf object, which means that the delete could use an incorrect address.
This fixes some cases where imposm-parser was stuck somewhere in the python library when reading PBF files.
The patch was tested by running a loop of "python imposm/parser/pbf/multiproc.py", which failed before the patch, and no longer fails with the patch.