From 8c6ecfe6488dff93090d5d0a2d814466804bc7de Mon Sep 17 00:00:00 2001 From: Chris Wilson Date: Wed, 29 Jul 2009 16:17:36 +0100 Subject: [perf] Remove the warning about failing to open a directory The warning is repeated in the error message if we fail to find any traces, and now that we search a path it is likely that some elements do not exist. Thus we annoy the user with irrelevant, non-fatal warnings. Still looking for suggestions for the most appropriate home for the system wide cairo-traces dir... --- perf/cairo-perf-trace.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) (limited to 'perf/cairo-perf-trace.c') diff --git a/perf/cairo-perf-trace.c b/perf/cairo-perf-trace.c index abe9b1e1..a7bfbbaa 100644 --- a/perf/cairo-perf-trace.c +++ b/perf/cairo-perf-trace.c @@ -655,10 +655,8 @@ cairo_perf_trace_dir (cairo_perf_t *perf, int num_traces = 0; dir = opendir (dirname); - if (dir == NULL) { - fprintf (stderr, "Failed to open directory '%s'\n", dirname); + if (dir == NULL) return 0; - } while ((de = readdir (dir)) != NULL) { char *trace; -- cgit v1.2.3