diff options
author | Vincent Sanders <vince@kyllikki.org> | 2015-05-28 16:08:46 +0100 |
---|---|---|
committer | Vincent Sanders <vince@kyllikki.org> | 2015-05-28 16:08:46 +0100 |
commit | c105738fa36bb2400adc47399c5b878d252d1c86 (patch) | |
tree | 138eeb449e1bf51ee1726b5f820740aada0ccd0b /riscos/content-handlers/draw.c | |
parent | 20f2c86a511f7913cf858e7bd3668b0b59663ba0 (diff) | |
download | netsurf-c105738fa36bb2400adc47399c5b878d252d1c86.tar.gz netsurf-c105738fa36bb2400adc47399c5b878d252d1c86.tar.bz2 |
Change LOG() macro to be varadic
This changes the LOG macro to be varadic removing the need for all
callsites to have double bracketing and allows for future improvement
on how we use the logging macros.
The callsites were changed with coccinelle and the changes checked by
hand. Compile tested for several frontends but not all.
A formatting annotation has also been added which allows the compiler
to check the parameters and types passed to the logging.
Diffstat (limited to 'riscos/content-handlers/draw.c')
-rw-r--r-- | riscos/content-handlers/draw.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/riscos/content-handlers/draw.c b/riscos/content-handlers/draw.c index 552423980..c2524d496 100644 --- a/riscos/content-handlers/draw.c +++ b/riscos/content-handlers/draw.c @@ -122,8 +122,7 @@ bool draw_convert(struct content *c) error = xdrawfile_bbox(0, (drawfile_diagram *) data, (int) source_size, 0, &bbox); if (error) { - LOG(("xdrawfile_bbox: 0x%x: %s", - error->errnum, error->errmess)); + LOG("xdrawfile_bbox: 0x%x: %s", error->errnum, error->errmess); msg_data.error = error->errmess; content_broadcast(c, CONTENT_MSG_ERROR, msg_data); return false; @@ -205,8 +204,7 @@ bool draw_redraw(struct content *c, struct content_redraw_data *data, error = xdrawfile_render(0, (drawfile_diagram *) src_data, (int) source_size, &matrix, 0, 0); if (error) { - LOG(("xdrawfile_render: 0x%x: %s", - error->errnum, error->errmess)); + LOG("xdrawfile_render: 0x%x: %s", error->errnum, error->errmess); return false; } |