From: Jérémie Galarneau Date: Fri, 4 Sep 2015 21:34:44 +0000 (-0400) Subject: Fix: Invalid parameter error reported when untracking PID X-Git-Tag: v2.7.0-rc2~77 X-Git-Url: https://git.lttng.org./?a=commitdiff_plain;h=c554d61c3723b9952e1f6d30fd210d99cf17586d;p=lttng-tools.git Fix: Invalid parameter error reported when untracking PID The LTTng client reports an "Invalid parameter" error if a PID is untracked from the userspace domain before any PID is tracked in that domain. Fixes #931 Signed-off-by: Jérémie Galarneau --- diff --git a/src/bin/lttng-sessiond/trace-ust.c b/src/bin/lttng-sessiond/trace-ust.c index befd5a61b..03fb38180 100644 --- a/src/bin/lttng-sessiond/trace-ust.c +++ b/src/bin/lttng-sessiond/trace-ust.c @@ -787,7 +787,8 @@ int trace_ust_untrack_pid(struct ltt_ust_session *session, int pid) struct ust_app *app; if (!session->pid_tracker.ht) { - retval = LTTNG_ERR_INVALID; + /* No PID being tracked. */ + retval = LTTNG_ERR_PID_NOT_TRACKED; goto end; } /* Remove PID from tracker */