Fix: only initialize syscall table if kernel tracer available
[lttng-tools.git] / src / bin / lttng-sessiond / main.c
index e5054735efd6279aec0fe5648a122dca3f366943..c1e6db1d44fcb5bf564703f9f3cd3df0b28f44f6 100644 (file)
@@ -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.");
+                               }
                        }
                }
 
This page took 0.035314 seconds and 5 git commands to generate.