drivers:usb:common:fsl-dt-fixup: fix return value of fdt_usb_get_node_type
[platform/kernel/u-boot.git] / tools / proftool.c
index 9ce7a77..ddf870f 100644 (file)
@@ -432,9 +432,10 @@ static int read_trace_config(FILE *fin)
 
                err = regcomp(&line->regex, tok, REG_NOSUB);
                if (err) {
+                       int r = regex_report_error(&line->regex, err,
+                                                  "compile", tok);
                        free(line);
-                       return regex_report_error(&line->regex, err, "compile",
-                                                 tok);
+                       return r;
                }
 
                /* link this new one to the end of the list */