*/
#include "lttng/lttng-error.h"
-#include <common/error.h>
-#include <common/hashtable/hashtable.h>
-#include <common/hashtable/utils.h>
-#include <common/macros.h>
-#include <common/mi-lttng.h>
-#include <common/payload-view.h>
-#include <common/payload.h>
+#include <common/error.hpp>
+#include <common/hashtable/hashtable.hpp>
+#include <common/hashtable/utils.hpp>
+#include <common/macros.hpp>
+#include <common/mi-lttng.hpp>
+#include <common/payload-view.hpp>
+#include <common/payload.hpp>
#include <fcntl.h>
#include <lttng/constant.h>
-#include <lttng/kernel-probe-internal.h>
+#include <lttng/kernel-probe-internal.hpp>
#include <lttng/kernel-probe.h>
#include <sys/stat.h>
#include <sys/types.h>
struct lttng_kernel_probe_location *ret = NULL;
struct lttng_kernel_probe_location_address *location;
- location = (lttng_kernel_probe_location_address *) zmalloc(sizeof(*location));
+ location = zmalloc<lttng_kernel_probe_location_address>();
if (!location) {
PERROR("Error allocating userspace probe location.");
goto end;
goto error;
}
- location = (lttng_kernel_probe_location_symbol *) zmalloc(sizeof(*location));
+ location = zmalloc<lttng_kernel_probe_location_symbol>();
if (!location) {
PERROR("Failed to allocate kernel symbol probe location");
goto error;