*
*/
-#include <common/defaults.h>
-#include <common/error.h>
-#include <common/hashtable/utils.h>
-#include <common/macros.h>
-#include <common/optional.h>
-#include <common/string-utils/format.h>
-#include <common/utils.h>
+#include <common/defaults.hpp>
+#include <common/error.hpp>
+#include <common/hashtable/utils.hpp>
+#include <common/macros.hpp>
+#include <common/optional.hpp>
+#include <common/string-utils/format.hpp>
+#include <common/utils.hpp>
#include <inttypes.h>
#include <lttng/constant.h>
#include <sys/stat.h>
#include <urcu/rculfhash.h>
#include <urcu/ref.h>
-#include "inode.h"
+#include "inode.hpp"
struct inode_id {
dev_t device;
struct lttng_unlinked_file_pool *lttng_unlinked_file_pool_create(
const char *path)
{
- struct lttng_unlinked_file_pool *pool = (lttng_unlinked_file_pool *) zmalloc(sizeof(*pool));
+ struct lttng_unlinked_file_pool *pool = zmalloc<lttng_unlinked_file_pool>();
if (!pool) {
goto error;
reference_acquired = lttng_directory_handle_get(directory_handle);
LTTNG_ASSERT(reference_acquired);
- inode = (lttng_inode *) zmalloc(sizeof(*inode));
+ inode = zmalloc<lttng_inode>();
if (!inode) {
goto end;
}
struct lttng_inode_registry *lttng_inode_registry_create(void)
{
- struct lttng_inode_registry *registry = (lttng_inode_registry *) zmalloc(sizeof(*registry));
+ struct lttng_inode_registry *registry = zmalloc<lttng_inode_registry>();
if (!registry) {
goto end;