mirror of
https://github.com/moparisthebest/wget
synced 2024-07-03 16:38:41 -04:00
Fix leak in HSTS code
* src/hsts.c (hsts_store_open): close fp if open.
This commit is contained in:
parent
994c4dcce7
commit
478a584609
@ -485,10 +485,12 @@ hsts_store_open (const char *filename)
|
||||
|
||||
if (fstat (fileno (fp), &st) == 0)
|
||||
store->last_mtime = st.st_mtime;
|
||||
fclose (fp);
|
||||
}
|
||||
|
||||
out:
|
||||
if (fp)
|
||||
fclose (fp);
|
||||
|
||||
return store;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user