Add type-checked versions of allocation and deallocations functions
[lttng-tools.git] / src / common / trigger.cpp
index be2c49b7cd3d79a03dc61eb1ed12e90c23321825..8e6f0734e8c811c7cf4ed9e5e1b64f92d1a8c7ae 100644 (file)
@@ -55,7 +55,7 @@ struct lttng_trigger *lttng_trigger_create(
                goto end;
        }
 
-       trigger = (lttng_trigger *) zmalloc(sizeof(struct lttng_trigger));
+       trigger = zmalloc<lttng_trigger>();
        if (!trigger) {
                goto end;
        }
@@ -505,7 +505,7 @@ struct lttng_triggers *lttng_triggers_create(void)
 {
        struct lttng_triggers *triggers = NULL;
 
-       triggers = (lttng_triggers *) zmalloc(sizeof(*triggers));
+       triggers = zmalloc<lttng_triggers>();
        if (!triggers) {
                goto end;
        }
This page took 0.023364 seconds and 4 git commands to generate.