Introduction
Introduction Statistics Contact Development Disclaimer Help
surf-adblock: remove unused headers and p->view - surf-adblock - Surf adblock w…
git clone git://git.codemadness.org/surf-adblock
Log
Files
Refs
README
LICENSE
---
commit 753df3b16e9c048fdb6680769326cc10c8e0a930
parent 55fbb08b97fe45d1d104f99ec1fe43261f322865
Author: Hiltjo Posthuma <[email protected]>
Date: Sun, 4 Jun 2017 14:29:17 +0200
surf-adblock: remove unused headers and p->view
don't depend on util functions in this file.
Diffstat:
M surf-adblock.c | 12 +-----------
1 file changed, 1 insertion(+), 11 deletions(-)
---
diff --git a/surf-adblock.c b/surf-adblock.c
@@ -1,10 +1,4 @@
-#include <sys/stat.h>
-#include <sys/types.h>
-
-#include <ctype.h>
#include <errno.h>
-#include <fcntl.h>
-#include <limits.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
@@ -17,7 +11,6 @@
typedef struct Page {
guint64 id;
WebKitWebPage *webpage;
- /*WebKitDOMDOMWindow *view;*/
struct Page *next;
} Page;
@@ -50,8 +43,6 @@ documentloaded(WebKitWebPage *wp, Page *p)
const char *uri = webkit_web_page_get_uri(p->webpage);
char *css, *globalcss;
- /*p->view = webkit_dom_document_get_default_view(doc);*/
-
if ((globalcss = getglobalcss())) {
el = webkit_dom_document_create_element(doc, "style", NULL);
webkit_dom_element_set_attribute(el, "type", "text/css", NULL);
@@ -94,8 +85,7 @@ webpagecreated(WebKitWebExtension *e, WebKitWebPage *p, gpoin…
Page *np;
if (!(np = newpage(p))) {
- weprintf("cannot associate webext with new page: %s\n",
- strerror(errno));
+ fprintf(stderr, "surf-adblock: cannot associate webext with ne…
return;
}
You are viewing proxied material from codemadness.org. The copyright of proxied material belongs to its original authors. Any comments or complaints in relation to proxied material should be directed to the original authors of the content concerned. Please see the disclaimer for more details.