Fix string leakage
svn path=/trunk/netsurf/; revision=12708
This commit is contained in:
parent
6807fa854d
commit
e82474afed
|
@ -399,8 +399,10 @@ static nserror mimesniff__compute_image(lwc_string *official_type,
|
|||
|
||||
const struct it_s *it;
|
||||
|
||||
if (data == NULL)
|
||||
if (data == NULL) {
|
||||
lwc_string_unref(official_type);
|
||||
return NSERROR_NEED_DATA;
|
||||
}
|
||||
|
||||
for (it = image_types; it->sig != NULL; it++) {
|
||||
if (it->len <= len && memcmp(data, it->sig, it->len) == 0) {
|
||||
|
|
Loading…
Reference in New Issue