diff options
author | portix <none@none> | 2013-02-23 14:51:31 +0100 |
---|---|---|
committer | portix <none@none> | 2013-02-23 14:51:31 +0100 |
commit | 4a71699b41b91f0251d2f35174db168bbca7d277 (patch) | |
tree | 06b27eb8a7947001daa99160e5ffd92749be05fa /src/plugins.c | |
parent | ca0edc249144007571dc54fd432fa2a651d6f53b (diff) | |
download | dwb-4a71699b41b91f0251d2f35174db168bbca7d277.zip |
Check if message has a firstParty property in requestpolicy; set width of plugin blocker if size and width cannot be computed
Diffstat (limited to 'src/plugins.c')
-rw-r--r-- | src/plugins.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/plugins.c b/src/plugins.c index 10f98f83..3dcef247 100644 --- a/src/plugins.c +++ b/src/plugins.c @@ -95,9 +95,9 @@ plugins_create_click_element(WebKitDOMElement *element, GList *gl) char *left = webkit_dom_css_style_declaration_get_property_value(style, "left"); char *position = webkit_dom_css_style_declaration_get_property_value(style, "position"); int w, h; - if (sscanf(width, "%dpx", &w) == 1 && w<72) + if (*width == '\0' || (sscanf(width, "%dpx", &w) == 1 && w<72)) w = 72; - if (sscanf(height, "%dpx", &h) == 1 && h<24) + if (*height == '\0' || (sscanf(height, "%dpx", &h) == 1 && h<24)) h = 24; |