X-Git-Url: https://git.lttng.org/?p=lttng-tools.git;a=blobdiff_plain;f=src%2Flib%2Flttng-ctl%2Fsnapshot.cpp;fp=src%2Flib%2Flttng-ctl%2Fsnapshot.cpp;h=baec7357f6b8c3becf5a90df7937ed63aba64810;hp=b9bac9aa84b0c2d3cc90c4efcf6593922dbbc1af;hb=64803277bbdbe0a943360d918298a48157d9da55;hpb=60f1b42d6280b6bd386abb726dca4fd3b31d8491 diff --git a/src/lib/lttng-ctl/snapshot.cpp b/src/lib/lttng-ctl/snapshot.cpp index b9bac9aa8..baec7357f 100644 --- a/src/lib/lttng-ctl/snapshot.cpp +++ b/src/lib/lttng-ctl/snapshot.cpp @@ -120,7 +120,7 @@ int lttng_snapshot_list_output(const char *session_name, goto error; } - new_list = (lttng_snapshot_output_list *) zmalloc(sizeof(*new_list)); + new_list = zmalloc(); if (!new_list) { ret = -LTTNG_ERR_NOMEM; goto error; @@ -240,7 +240,7 @@ struct lttng_snapshot_output *lttng_snapshot_output_create(void) { struct lttng_snapshot_output *output; - output = (lttng_snapshot_output *) zmalloc(sizeof(struct lttng_snapshot_output)); + output = zmalloc(); if (!output) { goto error; }