src.ctf.fs: make ctf_fs_trace::metadata a unique_ptr
[babeltrace.git] / src / plugins / ctf / fs-src / fs.hpp
index 97a8357352d4cdde4ca900a95819f703985e652f..bd9bfb9767e9a6292eb450c7883a13816840d7d1 100644 (file)
@@ -24,18 +24,16 @@ extern bool ctf_fs_debug;
 
 struct ctf_fs_metadata
 {
+    using UP = std::unique_ptr<ctf_fs_metadata>;
+
     /* Owned by this */
     ctf_metadata_decoder_up decoder;
 
-    /* Owned by this */
-    bt_trace_class *trace_class = nullptr;
+    bt2::TraceClass::Shared trace_class;
 
     /* Weak (owned by `decoder` above) */
     struct ctf_trace_class *tc = nullptr;
 
-    /* Owned by this */
-    char *text = nullptr;
-
     int bo = 0;
 };
 
@@ -55,16 +53,13 @@ struct ctf_fs_trace
 
     bt2c::Logger logger;
 
-    /* Owned by this */
-    struct ctf_fs_metadata *metadata = nullptr;
+    ctf_fs_metadata::UP metadata;
 
-    /* Owned by this */
-    bt_trace *trace = nullptr;
+    bt2::Trace::Shared trace;
 
     std::vector<ctf_fs_ds_file_group::UP> ds_file_groups;
 
-    /* Owned by this */
-    GString *path = nullptr;
+    std::string path;
 
     /* Next automatic stream ID when not provided by packet header */
     uint64_t next_stream_id = 0;
This page took 0.023837 seconds and 4 git commands to generate.