[lttng-dev] [PATCH lttng-tools] Fix: return NULL pointer on memory allocation failure
Mathieu Desnoyers
mathieu.desnoyers at efficios.com
Mon May 8 11:48:52 UTC 2017
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers at efficios.com>
---
src/common/buffer-usage.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/common/buffer-usage.c b/src/common/buffer-usage.c
index 49696a3..dfe0d85 100644
--- a/src/common/buffer-usage.c
+++ b/src/common/buffer-usage.c
@@ -231,7 +231,7 @@ struct lttng_condition *lttng_condition_buffer_usage_create(
condition = zmalloc(sizeof(struct lttng_condition_buffer_usage));
if (!condition) {
- goto end;
+ return NULL;
}
lttng_condition_init(&condition->parent, type);
--
2.1.4
More information about the lttng-dev
mailing list