Commit e2b1051a authored by Manuel Günther's avatar Manuel Günther
Browse files

Fixed memory leak in HDF5 copy constructor

parent d5ed9116
......@@ -121,11 +121,12 @@ static int PyBobIoHDF5File_Init(PyBobIoHDF5FileObject* self,
auto k_ = make_safe(k);
if (
(kwds && PyDict_Contains(kwds, k)) ||
(args && PyBobIoHDF5File_Check(PyTuple_GetItem(args, 0)))
(args && PyBobIoHDF5File_Check(PyTuple_GET_ITEM(args, 0)))
){
PyBobIoHDF5FileObject* other;
if (!PyArg_ParseTupleAndKeywords(args, kwds, "O&", kwlist2, &PyBobIoHDF5File_Converter, &other))
return -1;
auto other_ = make_safe(other);
self->f = other->f;
return 0;
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment