Fix: lttng: add-trigger: leak of argpar state
[lttng-tools.git] / src / bin / lttng / commands / add_trigger.c
index 9d013122d76a812038ef369798f289b6aebaf995..0c714d84962bcaf0d9a1b697bba27de0fefa1dc4 100644 (file)
@@ -789,6 +789,7 @@ end:
        free(filter);
        free(exclude);
        free(loglevel_str);
+       free(source);
        strutils_free_null_terminated_array_of_strings(exclusion_list);
        lttng_kernel_probe_location_destroy(kernel_probe_location);
        lttng_userspace_probe_location_destroy(userspace_probe_location);
@@ -1113,8 +1114,10 @@ struct lttng_action *handle_action_simple_session(
 error:
        lttng_action_destroy(action);
        action = NULL;
-       free(error);
+       argpar_item_destroy(item);
 end:
+       free(error);
+       argpar_state_destroy(state);
        return action;
 }
 
@@ -1439,7 +1442,9 @@ end:
        free(ctrl_url_arg);
        free(data_url_arg);
        free(snapshot_output);
+       free(max_size_arg);
        argpar_state_destroy(state);
+       argpar_item_destroy(item);
        return action;
 }
 
This page took 0.024062 seconds and 4 git commands to generate.