Browse Source

fix refleak in error condition

pull/40/head
Benjamin Peterson 11 years ago
parent
commit
ef9cf08352
  1. 1
      Modules/zipimport.c

1
Modules/zipimport.c

@ -1127,6 +1127,7 @@ get_data(PyObject *archive, PyObject *toc_entry)
bytes_read = fread(buf, 1, data_size, fp);
} else {
fclose(fp);
Py_DECREF(raw_data);
PyErr_Format(ZipImportError, "can't read Zip file: %R", archive);
return NULL;
}

Loading…
Cancel
Save