From a1dcaf0fdbfbaf02ef38886b556c3d37e4458fdc Mon Sep 17 00:00:00 2001 From: David Goulet Date: Tue, 25 Jun 2013 15:24:35 -0400 Subject: [PATCH] Fix: possible infinite loop in disable ust event Fixes #575 Signed-off-by: David Goulet --- src/bin/lttng-sessiond/event.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/bin/lttng-sessiond/event.c b/src/bin/lttng-sessiond/event.c index 0af7b4cb2..9a8ed63d1 100644 --- a/src/bin/lttng-sessiond/event.c +++ b/src/bin/lttng-sessiond/event.c @@ -527,8 +527,7 @@ int event_ust_disable_tracepoint(struct ltt_ust_session *usess, if (uevent->enabled == 0) { /* It's already disabled so everything is OK */ - ret = LTTNG_OK; - continue; + goto next; } ret = ust_app_disable_event_glb(usess, uchan, uevent); @@ -541,6 +540,7 @@ int event_ust_disable_tracepoint(struct ltt_ust_session *usess, DBG2("Event UST %s disabled in channel %s", uevent->attr.name, uchan->name); +next: /* Get next duplicate event by name. */ cds_lfht_next_duplicate(ht->ht, trace_ust_ht_match_event_by_name, event_name, &iter.iter); -- 2.34.1