mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-11-30 00:01:50 +00:00
Bug 1021142 - 'fclose()' at 2 places to avoid leaks on failure. r=bbondy
This commit is contained in:
parent
36bed62589
commit
903c685d53
@ -236,6 +236,7 @@ refresh_product_info_block(const char *path,
|
||||
if (fread(&additionalBlockSize,
|
||||
sizeof(additionalBlockSize),
|
||||
1, fp) != 1) {
|
||||
fclose(fp);
|
||||
return -1;
|
||||
}
|
||||
additionalBlockSize = ntohl(additionalBlockSize);
|
||||
@ -244,6 +245,7 @@ refresh_product_info_block(const char *path,
|
||||
if (fread(&additionalBlockID,
|
||||
sizeof(additionalBlockID),
|
||||
1, fp) != 1) {
|
||||
fclose(fp);
|
||||
return -1;
|
||||
}
|
||||
additionalBlockID = ntohl(additionalBlockID);
|
||||
|
Loading…
Reference in New Issue
Block a user