Fix: Dereference null return value
[babeltrace.git] / lib / ctf-ir / resolve.c
index b4a9c58cb821df1753921ecfae6d9e8d08c2a631..c8648254faed43eaadf540e2b09d9059696d3de2 100644 (file)
@@ -1023,6 +1023,12 @@ int resolve_sequence_or_variant_type(struct bt_ctf_field_type *type,
                abort();
        }
 
+       if (!pathstr) {
+               BT_LOGW_STR("Cannot get path string.");
+               ret = -1;
+               goto end;
+       }
+
        /* Get target field path out of path string */
        target_field_path = pathstr_to_field_path(pathstr, ctx);
        if (!target_field_path) {
This page took 0.023392 seconds and 4 git commands to generate.