Always evaluate BT_ASSERT(); add BT_ASSERT_DBG() for debug mode only
[babeltrace.git] / src / plugins / ctf / fs-src / fs.c
index ee322c0e50851d1b4e107f977776fe974c05f38b..e92de4bca52a0b4db2593f25862668a6388e0c7a 100644 (file)
@@ -118,7 +118,7 @@ bt_component_class_message_iterator_next_method_status ctf_fs_iterator_next_one(
 {
        bt_component_class_message_iterator_next_method_status status;
 
-       BT_ASSERT(msg_iter_data->ds_file);
+       BT_ASSERT_DBG(msg_iter_data->ds_file);
 
        while (true) {
                bt_message *msg;
@@ -785,8 +785,11 @@ int add_ds_file_to_ds_file_group(struct ctf_fs_trace *ctf_fs_trace,
 
        index = ctf_fs_ds_file_build_index(ds_file, ds_file_info);
        if (!index) {
-               BT_COMP_LOGW("Failed to index CTF stream file \'%s\'",
+               BT_COMP_OR_COMP_CLASS_LOGE_APPEND_CAUSE(
+                       self_comp, self_comp_class,
+                       "Failed to index CTF stream file \'%s\'",
                        ds_file->file->path->str);
+               goto error;
        }
 
        if (begin_ns == -1) {
This page took 0.023973 seconds and 4 git commands to generate.