plugin: fix forbidden_product_strings check in apply_post_probing_filters
This patch fixes a bug in apply_post_probing_filters() where it iterates through `self->priv->forbidden_product_strings' but incorrectly accesses `self->priv->product_strings[i]' inside the loop. `self->priv->forbidden_product_strings[i]' should be accessed instead.
This commit is contained in:
@@ -535,8 +535,8 @@ apply_post_probing_filters (MMPlugin *self,
|
|||||||
gchar *casefolded_vendor;
|
gchar *casefolded_vendor;
|
||||||
gchar *casefolded_product;
|
gchar *casefolded_product;
|
||||||
|
|
||||||
casefolded_vendor = g_utf8_casefold (self->priv->product_strings[i].l, -1);
|
casefolded_vendor = g_utf8_casefold (self->priv->forbidden_product_strings[i].l, -1);
|
||||||
casefolded_product = g_utf8_casefold (self->priv->product_strings[i].r, -1);
|
casefolded_product = g_utf8_casefold (self->priv->forbidden_product_strings[i].r, -1);
|
||||||
found = (!!strstr (vendor, casefolded_vendor) &&
|
found = (!!strstr (vendor, casefolded_vendor) &&
|
||||||
!!strstr (product, casefolded_product));
|
!!strstr (product, casefolded_product));
|
||||||
g_free (casefolded_vendor);
|
g_free (casefolded_vendor);
|
||||||
|
Reference in New Issue
Block a user