perf tools: Add missing closedir in multi tracepoint processing
authorJiri Olsa <[email protected]>
Mon, 17 Dec 2012 13:08:36 +0000 (14:08 +0100)
committerArnaldo Carvalho de Melo <[email protected]>
Thu, 24 Jan 2013 19:40:10 +0000 (16:40 -0300)
We don't close 'events' directory when reading multiple tracepoint
events. Adding missing closedir.

Signed-off-by: Jiri Olsa <[email protected]>
Cc: Corey Ashford <[email protected]>
Cc: Frederic Weisbecker <[email protected]>
Cc: Ingo Molnar <[email protected]>
Cc: Namhyung Kim <[email protected]>
Cc: Paul Mackerras <[email protected]>
Cc: Peter Zijlstra <[email protected]>
Link: http://lkml.kernel.org/r/[email protected]
Signed-off-by: Arnaldo Carvalho de Melo <[email protected]>
tools/perf/util/parse-events.c

index 2d8d53bec17e35dd58f1eced0a710f48980f2ec2..d64ff299a3b3aaea9aba52c557ac934b1897c898 100644 (file)
@@ -408,6 +408,7 @@ static int add_tracepoint_multi(struct list_head **list, int *idx,
                ret = add_tracepoint(list, idx, sys_name, evt_ent->d_name);
        }
 
+       closedir(evt_dir);
        return ret;
 }