summaryrefslogtreecommitdiff
path: root/tools/lib/api/fs/tracing_path.c
diff options
context:
space:
mode:
Diffstat (limited to 'tools/lib/api/fs/tracing_path.c')
-rw-r--r--tools/lib/api/fs/tracing_path.c13
1 files changed, 13 insertions, 0 deletions
diff --git a/tools/lib/api/fs/tracing_path.c b/tools/lib/api/fs/tracing_path.c
index 9cd282425929..9b451af0721c 100644
--- a/tools/lib/api/fs/tracing_path.c
+++ b/tools/lib/api/fs/tracing_path.c
@@ -101,6 +101,19 @@ void put_events_file(char *file)
free(file);
}
+DIR *tracing_events__opendir(void)
+{
+ DIR *dir = NULL;
+ char *path = get_tracing_file("events");
+
+ if (path) {
+ dir = opendir(path);
+ put_events_file(path);
+ }
+
+ return dir;
+}
+
int tracing_path__strerror_open_tp(int err, char *buf, size_t size,
const char *sys, const char *name)
{