Fix: mi: snapshot: missing error handling for session name
authorJonathan Rajotte <jonathan.rajotte-julien@efficios.com>
Tue, 6 Jan 2015 15:59:47 +0000 (10:59 -0500)
committerJérémie Galarneau <jeremie.galarneau@efficios.com>
Thu, 8 Jan 2015 19:48:22 +0000 (14:48 -0500)
Signed-off-by: Jonathan Rajotte <jonathan.rajotte-julien@efficios.com>
Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
src/common/mi-lttng.c

index 752bcecebd9fc48f7558651395a59b56750c868b..fed09854a206012482d320b770f666ed9b3cdb53 100644 (file)
@@ -1341,6 +1341,9 @@ int mi_lttng_snapshot_output_session_name(struct mi_writer *writer,
        /* Snapshot output list for current session name */
        ret = mi_lttng_writer_write_element_string(writer, config_element_name,
                        session_name);
+       if (ret) {
+               goto end;
+       }
 
        /* Open element snapshots (sequence one snapshot) */
        ret = mi_lttng_writer_open_element(writer, mi_lttng_element_snapshots);
This page took 0.026075 seconds and 4 git commands to generate.