summaryrefslogtreecommitdiff
path: root/util
diff options
context:
space:
mode:
authorAndrea Canciani <ranma42@gmail.com>2011-03-18 16:36:12 +0100
committerAndrea Canciani <ranma42@gmail.com>2011-03-18 17:54:54 +0100
commitad458d816a60613ee408d96bee8b77c64e6633e3 (patch)
tree2b32d689a946dfbb0a5703ce0c7c0d3ce16ebc58 /util
parentf2eb3f2178b6b7a75da4fb5e5bd880b769b69e62 (diff)
trace: Always emit a function name for write-to-png-stream
By emitting an empty function name when it it impossible to perform the lookup, we can get rid of the warning: trace.c:3714: warning: unused variable ‘symbol’ Additionally, this makes the syntax (or, rather, the parameter count) for write-to-png-stream the same on every configuration.
Diffstat (limited to 'util')
-rw-r--r--util/cairo-trace/trace.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/util/cairo-trace/trace.c b/util/cairo-trace/trace.c
index ff2bc81d..9bdeb01a 100644
--- a/util/cairo-trace/trace.c
+++ b/util/cairo-trace/trace.c
@@ -3715,10 +3715,11 @@ cairo_surface_write_to_png_stream (cairo_surface_t *surface,
_trace_printf ("%% s%ld ", _get_surface_id (surface));
#if CAIRO_HAS_SYMBOL_LOOKUP
- _emit_string_literal (lookup_symbol (symbol, sizeof (symbol),
- write_func),
- -1);
+ lookup_symbol (symbol, sizeof (symbol), write_func);
+#else
+ symbol[0] = '\0';
#endif
+ _emit_string_literal (symbol, -1);
_trace_printf (" write-to-png-stream\n");
_write_unlock ();
}