From 89588270089b3c4ae5ef4291cdd87960e5d3d297 Mon Sep 17 00:00:00 2001 From: David Goulet Date: Wed, 1 Oct 2014 11:30:15 -0400 Subject: [PATCH] Fix: only initialize syscall table if kernel tracer available Fixes #844 Signed-off-by: David Goulet --- src/bin/lttng-sessiond/main.c | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/src/bin/lttng-sessiond/main.c b/src/bin/lttng-sessiond/main.c index e5054735e..c1e6db1d4 100644 --- a/src/bin/lttng-sessiond/main.c +++ b/src/bin/lttng-sessiond/main.c @@ -5230,10 +5230,12 @@ int main(int argc, char **argv) /* Setup kernel tracer */ if (!opt_no_kernel) { init_kernel_tracer(); - ret = syscall_init_table(); - if (ret < 0) { - ERR("Unable to populate syscall table. Syscall tracing won't" - " work for this session daemon."); + if (kernel_tracer_fd >= 0) { + ret = syscall_init_table(); + if (ret < 0) { + ERR("Unable to populate syscall table. Syscall tracing" + " won't work for this session daemon."); + } } } -- 2.34.1