Do reset sig in adblock_is_matched_by_key
This commit is contained in:
parent
0e93695979
commit
de89a988f0
1 changed files with 2 additions and 1 deletions
|
@ -650,6 +650,7 @@ adblock_is_matched_by_key (const gchar* req_uri,
|
|||
gboolean ret = FALSE;
|
||||
gchar sig[SIGNATURE_SIZE + 1];
|
||||
|
||||
memset (&sig[0], 0, sizeof (sig));
|
||||
/* Signatures are made on pattern, so we need to convert url to a pattern as well */
|
||||
guri = adblock_fixup_regexp ("", (gchar*)req_uri);
|
||||
uri = guri->str;
|
||||
|
@ -665,7 +666,7 @@ adblock_is_matched_by_key (const gchar* req_uri,
|
|||
if (!regex || g_list_find (regex_bl, regex))
|
||||
continue;
|
||||
ret = adblock_check_rule (regex, sig, req_uri, page_uri);
|
||||
if (!ret)
|
||||
if (ret)
|
||||
break;
|
||||
regex_bl = g_list_prepend (regex_bl, regex);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue