X-Git-Url: http://git.efficios.com/?p=lttng-tools.git;a=blobdiff_plain;f=src%2Fbin%2Flttng-sessiond%2Fsyscall.c;h=c38f8910940f0b8bb990034ed4fa0fcef0360fef;hp=eb81d67429a2d96ac6b062db40940988ad0dd58c;hb=24eb8569dc841f318d7964ca9a0ad0a4f9508a8e;hpb=d069d57732e9a19624078b6e8ca424dbd5827fc0 diff --git a/src/bin/lttng-sessiond/syscall.c b/src/bin/lttng-sessiond/syscall.c index eb81d6742..c38f89109 100644 --- a/src/bin/lttng-sessiond/syscall.c +++ b/src/bin/lttng-sessiond/syscall.c @@ -405,11 +405,14 @@ ssize_t syscall_list_channel(struct ltt_kernel_channel *kchan, events = new_events; } + rcu_read_lock(); ksyscall = lookup_syscall(syscalls_ht, syscall_table[i].name); if (ksyscall) { update_event_syscall_bitness(events, i, ksyscall->index); continue; } + ksyscall = NULL; + rcu_read_unlock(); ret = add_syscall_to_ht(syscalls_ht, i, count); if (ret < 0) { @@ -429,7 +432,10 @@ ssize_t syscall_list_channel(struct ltt_kernel_channel *kchan, return count; error: + rcu_read_lock(); destroy_syscall_ht(syscalls_ht); + rcu_read_unlock(); + free(events); return ret; }