Add type-checked versions of allocation and deallocations functions
[lttng-tools.git] / src / bin / lttng-sessiond / kernel.cpp
index 9d256e2075373c7dbb1de925a2f759129e6742bd..f7d232ffc01aadb346b5fdf6d8c4928ea5163727 100644 (file)
@@ -1436,7 +1436,7 @@ ssize_t kernel_list_events(struct lttng_event **events)
         * See kernel-ctl.h for explanation of this value
         */
        nbmem = KERNEL_EVENT_INIT_LIST_SIZE;
-       elist = (lttng_event *) zmalloc(sizeof(struct lttng_event) * nbmem);
+       elist = calloc<lttng_event>(nbmem);
        if (elist == NULL) {
                PERROR("alloc list events");
                count = -ENOMEM;
This page took 0.024198 seconds and 4 git commands to generate.