X-Git-Url: https://git.liburcu.org/?a=blobdiff_plain;f=src%2Fcommon%2Fevent-rule%2Fpython-logging.cpp;h=25e967702436e2afc34708a067a32b1ea7ffccd8;hb=64803277bbdbe0a943360d918298a48157d9da55;hp=20b649648c13bb94bee1bab8b7cbdd3b4ee4e133;hpb=60f1b42d6280b6bd386abb726dca4fd3b31d8491;p=lttng-tools.git diff --git a/src/common/event-rule/python-logging.cpp b/src/common/event-rule/python-logging.cpp index 20b649648..25e967702 100644 --- a/src/common/event-rule/python-logging.cpp +++ b/src/common/event-rule/python-logging.cpp @@ -421,7 +421,7 @@ static struct lttng_event *lttng_event_rule_python_logging_generate_lttng_event( python_logging = container_of( rule, const struct lttng_event_rule_python_logging, parent); - local_event = (lttng_event *) zmalloc(sizeof(*local_event)); + local_event = zmalloc(); if (!local_event) { goto error; } @@ -560,7 +560,7 @@ struct lttng_event_rule *lttng_event_rule_python_logging_create(void) struct lttng_event_rule_python_logging *tp_rule; enum lttng_event_rule_status status; - tp_rule = (lttng_event_rule_python_logging *) zmalloc(sizeof(struct lttng_event_rule_python_logging)); + tp_rule = zmalloc(); if (!tp_rule) { goto end; }