type_decoder.c:206:2: warning: Potential leak of memory pointed to by 'pdb'
PyGILState_Release(gstate);
^~~~~~~~~~~~~~~~~~
goto err;
}
- pdb = g_malloc(sizeof(struct srd_proto_data_binary));
if (PyBytes_AsStringAndSize(py_tmp, &buf, &size) == -1)
goto err;
PyGILState_Release(gstate);
+ pdb = g_malloc(sizeof(struct srd_proto_data_binary));
pdb->bin_class = bin_class;
pdb->size = size;
if (!(pdb->data = g_try_malloc(pdb->size))) {