- Fixed: Attempt to free a non-heap object in zipdir.

SVN r2115 (trunk)
This commit is contained in:
Randy Heit 2010-01-18 05:07:10 +00:00
parent 6c9748b603
commit a3ac7ee081

View file

@ -1027,9 +1027,13 @@ int append_to_zip(FILE *zip_file, file_sorted_t *filep, FILE *ozip, BYTE *odir)
}
fprintf(stderr, "Unable to write %s to zip\n", file->path);
free(readbuf);
if (compbuf != NULL)
if (compbuf[0] != NULL)
{
free(compbuf);
free(compbuf[0]);
}
if (compbuf[1] != NULL)
{
free(compbuf[1]);
}
return 1;
}