Fix: uninitialized return value
authorMathieu Desnoyers <mathieu.desnoyers@efficios.com>
Fri, 23 Jan 2015 16:28:59 +0000 (11:28 -0500)
committerJérémie Galarneau <jeremie.galarneau@efficios.com>
Fri, 23 Jan 2015 21:48:01 +0000 (16:48 -0500)
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
src/bin/lttng-sessiond/ust-app.c

index fa8dc5fefdd1850a750aebdd0280e6780a7117fd..8f0b7faf7bba62b5318dfc54f1efa5df21c08da9 100644 (file)
@@ -4093,7 +4093,7 @@ static
 int ust_app_flush_session(struct ltt_ust_session *usess)
 
 {
-       int ret;
+       int ret = 0;
 
        DBG("Flushing session buffers for all ust apps");
 
@@ -4134,7 +4134,6 @@ int ust_app_flush_session(struct ltt_ust_session *usess)
                        /* Push metadata. */
                        (void) push_metadata(ust_session_reg, usess->consumer);
                }
-               ret = 0;
                break;
        }
        case LTTNG_BUFFER_PER_PID:
@@ -4153,6 +4152,7 @@ int ust_app_flush_session(struct ltt_ust_session *usess)
                break;
        }
        default:
+               ret = -1;
                assert(0);
                break;
        }
This page took 0.028671 seconds and 4 git commands to generate.