Add type-checked versions of allocation and deallocations functions
[lttng-tools.git] / src / common / consumer / metadata-bucket.cpp
index ed78ec9472f800e3b55358bd9c5e235135bf52e9..f9c35e22ce4c4d3e25521c53e02d91dc9694c1eb 100644 (file)
@@ -25,9 +25,7 @@ struct metadata_bucket {
 struct metadata_bucket *metadata_bucket_create(
                metadata_bucket_flush_cb flush, void *data)
 {
-       struct metadata_bucket *bucket;
-
-       bucket = (metadata_bucket *) zmalloc(sizeof(typeof(*bucket)));
+       metadata_bucket *bucket = zmalloc<metadata_bucket>();
        if (!bucket) {
                PERROR("Failed to allocate buffer bucket");
                goto end;
This page took 0.023974 seconds and 4 git commands to generate.