Fix code syntax
authorDavid Goulet <david.goulet@polymtl.ca>
Mon, 12 Dec 2011 20:58:34 +0000 (15:58 -0500)
committerDavid Goulet <david.goulet@polymtl.ca>
Mon, 12 Dec 2011 20:58:34 +0000 (15:58 -0500)
Signed-off-by: David Goulet <david.goulet@polymtl.ca>
lttng-sessiond/main.c

index 54859c8dc302883eccb9dc3c53563ab4eda7f89c..27d4c04de9314d08dbdd530752b7dd457c1c684b 100644 (file)
@@ -2772,8 +2772,11 @@ static int cmd_start_trace(struct ltt_session *session)
        ksession = session->kernel_session;
        usess = session->ust_session;
 
-       if (session->enabled)
-               return LTTCOMM_UST_START_FAIL;
+       if (session->enabled) {
+               ret = LTTCOMM_UST_START_FAIL;
+               goto error;
+       }
+
        session->enabled = 1;
 
        /* Kernel tracing */
@@ -2861,8 +2864,11 @@ static int cmd_stop_trace(struct ltt_session *session)
        ksession = session->kernel_session;
        usess = session->ust_session;
 
-       if (!session->enabled)
-               return LTTCOMM_UST_START_FAIL;
+       if (!session->enabled) {
+               ret = LTTCOMM_UST_START_FAIL;
+               goto error;
+       }
+
        session->enabled = 0;
 
        /* Kernel tracer */
This page took 0.037294 seconds and 4 git commands to generate.