#include <lttng/trigger/trigger.h>
#include <lttng/lttng-error.h>
-#include "notification-thread.h"
-#include "notification-thread-commands.h"
-#include <common/error.h>
+#include "notification-thread.hpp"
+#include "notification-thread-commands.hpp"
+#include <common/error.hpp>
#include <unistd.h>
#include <stdint.h>
#include <inttypes.h>
{
struct notification_thread_command *new_cmd;
- new_cmd = (notification_thread_command *) zmalloc(sizeof(*new_cmd));
+ new_cmd = zmalloc<notification_thread_command>();
if (!new_cmd) {
goto end;
}
LTTNG_ASSERT(domain != LTTNG_DOMAIN_NONE);
LTTNG_ASSERT((payload && payload_size) || (!payload && !payload_size));
- notification = (lttng_event_notifier_notification *) zmalloc(sizeof(struct lttng_event_notifier_notification));
+ notification = zmalloc<lttng_event_notifier_notification>();
if (notification == NULL) {
ERR("Error allocating notification");
goto end;