Cleanup: flt.lttng-utils.debug-info: remove leftover comments
[babeltrace.git] / src / plugins / lttng-utils / debug-info / trace-ir-metadata-copy.c
index 0bc9194fc4f6a38ee7859cbc3f3a3588fbfabb84..e0d73d87853d778123da6c5275bf1f8b360ff0de 100644 (file)
@@ -46,6 +46,13 @@ int copy_trace_class_content(const bt_trace_class *in_trace_class,
        BT_COMP_LOGD("Copying content of trace class: in-tc-addr=%p, out-tc-addr=%p",
                        in_trace_class, out_trace_class);
 
+       /*
+        * Safe to use the same value object because it's frozen at this
+        * point.
+        */
+       bt_trace_class_set_user_attributes(out_trace_class,
+               bt_trace_class_borrow_user_attributes_const(in_trace_class));
+
        /* Use the same stream class ids as in the origin trace class. */
        bt_trace_class_set_assigns_automatic_stream_class_id(out_trace_class,
                        BT_FALSE);
@@ -81,6 +88,13 @@ int copy_clock_class_content(const bt_clock_class *in_clock_class,
                }
        }
 
+       /*
+        * Safe to use the same value object because it's frozen at this
+        * point.
+        */
+       bt_clock_class_set_user_attributes(out_clock_class,
+               bt_clock_class_borrow_user_attributes_const(in_clock_class));
+
        clock_class_description = bt_clock_class_get_description(in_clock_class);
 
        if (clock_class_description) {
@@ -204,6 +218,13 @@ int copy_stream_class_content(struct trace_ir_maps *ir_maps,
 
        }
 
+       /*
+        * Safe to use the same value object because it's frozen at this
+        * point.
+        */
+       bt_stream_class_set_user_attributes(out_stream_class,
+               bt_stream_class_borrow_user_attributes_const(in_stream_class));
+
        bt_stream_class_set_supports_packets(
                out_stream_class,
                bt_stream_class_supports_packets(in_stream_class),
@@ -307,7 +328,6 @@ int copy_stream_class_content(struct trace_ir_maps *ir_maps,
                }
        }
 
-       /* Set packet snapshot boolean fields. */
        BT_COMP_LOGD("Copied content of stream class: in-sc-addr=%p, out-sc-addr=%p",
                        in_stream_class, out_stream_class);
 error:
@@ -345,6 +365,13 @@ int copy_event_class_content(struct trace_ir_maps *ir_maps,
                }
        }
 
+       /*
+        * Safe to use the same value object because it's frozen at this
+        * point.
+        */
+       bt_event_class_set_user_attributes(out_event_class,
+               bt_event_class_borrow_user_attributes_const(in_event_class));
+
        /* Copy event class loglevel. */
        prop_avail = bt_event_class_get_log_level(in_event_class,
                &ec_log_level);
This page took 0.023497 seconds and 4 git commands to generate.