Fix: event leak during event load
authorJérémie Galarneau <jeremie.galarneau@efficios.com>
Tue, 28 Aug 2018 16:15:03 +0000 (12:15 -0400)
committerJérémie Galarneau <jeremie.galarneau@efficios.com>
Tue, 28 Aug 2018 16:16:31 +0000 (12:16 -0400)
The currently processed lttng_event is now created using
its constructor rather than allocating the structure on the function's
stack. The destructor must thus be used.

Reported-by: Coverity Scan (1395210 Resource leak)
Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
src/common/config/session-config.c

index 78d0c8b73357fa91a01fcc3cacbe26a119800da2..595e743b45de0cc3de1e7a82de8b1a0d635e7bf7 100644 (file)
@@ -2052,6 +2052,7 @@ end:
                free(exclusions[i]);
        }
 
+       lttng_event_destroy(event);
        free(exclusions);
        free(filter_expression);
        return ret;
This page took 0.027563 seconds and 4 git commands to generate.