Fix: don't destroy the sockets if the snapshot was successful
authorJonathan Rajotte <jonathan.rajotte-julien@efficios.com>
Fri, 8 Feb 2019 01:25:42 +0000 (20:25 -0500)
committerJérémie Galarneau <jeremie.galarneau@efficios.com>
Mon, 11 Feb 2019 20:21:02 +0000 (15:21 -0500)
Missing a goto to skip the error condition that was destroying the
relayd sockets even if a snapshot was successful. We want to keep them
open to reuse them for the next snapshots.

This is verbatim from the fix 1371fc1228461eb532118280e67ab3e9de015757

It is also the same fix.

Signed-off-by: Jonathan Rajotte <jonathan.rajotte-julien@efficios.com>
Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
src/bin/lttng-sessiond/cmd.c

index d3c8376be1a01cf691f4a02be1ffe93c09c4a6b0..d91869fae8c5d69ac3c3ad88ca20e9a902d0f587 100644 (file)
@@ -4179,10 +4179,13 @@ static enum lttng_error_code record_ust_snapshot(struct ltt_ust_session *usess,
                goto error_snapshot;
        }
 
                goto error_snapshot;
        }
 
+       goto end;
+
 error_snapshot:
        /* Clean up copied sockets so this output can use some other later on. */
        consumer_destroy_output_sockets(output->consumer);
 error:
 error_snapshot:
        /* Clean up copied sockets so this output can use some other later on. */
        consumer_destroy_output_sockets(output->consumer);
 error:
+end:
        return status;
 }
 
        return status;
 }
 
This page took 0.039364 seconds and 5 git commands to generate.