diff options
Diffstat (limited to 'applypatch')
-rw-r--r-- | applypatch/imgdiff.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/applypatch/imgdiff.cpp b/applypatch/imgdiff.cpp index 77c19ad97..528daf113 100644 --- a/applypatch/imgdiff.cpp +++ b/applypatch/imgdiff.cpp @@ -224,6 +224,7 @@ unsigned char* ReadZip(const char* filename, for (i = 0; i < cdcount; ++i) { if (!(cd[0] == 0x50 && cd[1] == 0x4b && cd[2] == 0x01 && cd[3] == 0x02)) { printf("bad central directory entry %d\n", i); + free(temp_entries); return NULL; } @@ -1078,6 +1079,9 @@ int main(int argc, char** argv) { } } + free(patch_data); + free(patch_size); + fclose(f); return 0; |