diff options
author | Vincent Sanders <vince@kyllikki.org> | 2017-09-06 18:28:12 +0100 |
---|---|---|
committer | Vincent Sanders <vince@kyllikki.org> | 2017-09-06 18:45:27 +0100 |
commit | 75018632a9b953aafeae6f4e8aea607fd1d89dca (patch) | |
tree | d661d2fded2ad4b80c4cf019dee2954c052ab090 /frontends/framebuffer/framebuffer.c | |
parent | 8d9b2efc11529da8cb5870b39ff15249c648b10a (diff) | |
download | netsurf-75018632a9b953aafeae6f4e8aea607fd1d89dca.tar.gz netsurf-75018632a9b953aafeae6f4e8aea607fd1d89dca.tar.bz2 |
Use coccinelle to change logging macro calls in c files
for F in $(git ls-files '*.c');do spatch --sp-file foo.cocci --in-place ${F};done
@@ expression E; @@
-LOG(E);
+NSLOG(netsurf, INFO, E);
@@ expression E, E1; @@
-LOG(E, E1);
+NSLOG(netsurf, INFO, E, E1);
@@ expression E, E1, E2; @@
-LOG(E, E1, E2);
+NSLOG(netsurf, INFO, E, E1, E2);
@@ expression E, E1, E2, E3; @@
-LOG(E, E1, E2, E3);
+NSLOG(netsurf, INFO, E, E1, E2, E3);
@@ expression E, E1, E2, E3, E4; @@
-LOG(E, E1, E2, E3, E4);
+NSLOG(netsurf, INFO, E, E1, E2, E3, E4);
@@ expression E, E1, E2, E3, E4, E5; @@
-LOG(E, E1, E2, E3, E4, E5);
+NSLOG(netsurf, INFO, E, E1, E2, E3, E4, E5);
@@ expression E, E1, E2, E3, E4, E5, E6; @@
-LOG(E, E1, E2, E3, E4, E5, E6);
+NSLOG(netsurf, INFO, E, E1, E2, E3, E4, E5, E6);
@@ expression E, E1, E2, E3, E4, E5, E6, E7; @@
-LOG(E, E1, E2, E3, E4, E5, E6, E7);
+NSLOG(netsurf, INFO, E, E1, E2, E3, E4, E5, E6, E7);
Diffstat (limited to 'frontends/framebuffer/framebuffer.c')
-rw-r--r-- | frontends/framebuffer/framebuffer.c | 15 |
1 files changed, 8 insertions, 7 deletions
diff --git a/frontends/framebuffer/framebuffer.c b/frontends/framebuffer/framebuffer.c index de8a3695d..2ccc75062 100644 --- a/frontends/framebuffer/framebuffer.c +++ b/frontends/framebuffer/framebuffer.c @@ -271,7 +271,7 @@ framebuffer_plot_path(const struct redraw_context *ctx, float width, const float transform[6]) { - LOG("path unimplemented"); + NSLOG(netsurf, INFO, "path unimplemented"); return NSERROR_OK; } @@ -564,7 +564,7 @@ static bool framebuffer_format_from_bpp(int bpp, enum nsfb_format_e *fmt) break; default: - LOG("Bad bits per pixel (%d)\n", bpp); + NSLOG(netsurf, INFO, "Bad bits per pixel (%d)\n", bpp); return false; } @@ -586,18 +586,19 @@ framebuffer_initialise(const char *fename, int width, int height, int bpp) fbtype = nsfb_type_from_name(fename); if (fbtype == NSFB_SURFACE_NONE) { - LOG("The %s surface is not available from libnsfb\n", fename); + NSLOG(netsurf, INFO, + "The %s surface is not available from libnsfb\n", fename); return NULL; } nsfb = nsfb_new(fbtype); if (nsfb == NULL) { - LOG("Unable to create %s fb surface\n", fename); + NSLOG(netsurf, INFO, "Unable to create %s fb surface\n", fename); return NULL; } if (nsfb_set_geometry(nsfb, width, height, fbfmt) == -1) { - LOG("Unable to set surface geometry\n"); + NSLOG(netsurf, INFO, "Unable to set surface geometry\n"); nsfb_free(nsfb); return NULL; } @@ -605,7 +606,7 @@ framebuffer_initialise(const char *fename, int width, int height, int bpp) nsfb_cursor_init(nsfb); if (nsfb_init(nsfb) == -1) { - LOG("Unable to initialise nsfb surface\n"); + NSLOG(netsurf, INFO, "Unable to initialise nsfb surface\n"); nsfb_free(nsfb); return NULL; } @@ -625,7 +626,7 @@ framebuffer_resize(nsfb_t *nsfb, int width, int height, int bpp) } if (nsfb_set_geometry(nsfb, width, height, fbfmt) == -1) { - LOG("Unable to change surface geometry\n"); + NSLOG(netsurf, INFO, "Unable to change surface geometry\n"); return false; } |