Port: Fix libuuid compat on mingw
[babeltrace.git] / lib / ctf-ir / trace.c
index 6515dfe8ceb3387eadf957baafe21d954bf29c40..37fa2763f93859fb265cabdfb15c40ee50c6428b 100644 (file)
@@ -93,7 +93,6 @@ const unsigned int field_type_aliases_sizes[] = {
 struct bt_ctf_trace *bt_ctf_trace_create(void)
 {
        struct bt_ctf_trace *trace = NULL;
-       struct bt_ctf_field_type *packet_header_type = NULL;
 
        trace = g_new0(struct bt_ctf_trace, 1);
        if (!trace) {
@@ -125,13 +124,6 @@ struct bt_ctf_trace *bt_ctf_trace_create(void)
                goto error;
        }
 
-       packet_header_type = bt_ctf_field_type_structure_create();
-       if (!packet_header_type) {
-               goto error;
-       }
-
-       BT_MOVE(trace->packet_header_type, packet_header_type);
-
        /* Create the environment array object */
        trace->environment = bt_ctf_attributes_create();
        if (!trace->environment) {
@@ -158,7 +150,6 @@ struct bt_ctf_trace *bt_ctf_trace_create(void)
 
 error:
        BT_PUT(trace);
-       bt_put(packet_header_type);
        return trace;
 }
 
@@ -247,7 +238,7 @@ int bt_ctf_trace_set_uuid(struct bt_ctf_trace *trace, const unsigned char *uuid)
                goto end;
        }
 
-       memcpy(trace->uuid, uuid, sizeof(uuid_t));
+       memcpy(trace->uuid, uuid, BABELTRACE_UUID_LEN);
        trace->uuid_set = BT_TRUE;
        BT_LOGV("Set trace's UUID: addr=%p, name=\"%s\", "
                "uuid=\"%02x%02x%02x%02x-%02x%02x-%02x%02x-%02x%02x-%02x%02x%02x%02x%02x%02x\"",
This page took 0.028621 seconds and 4 git commands to generate.