{
ssize_t used_size = 0;
struct lttng_error_query_comm *header;
+ struct lttng_trigger *trigger = NULL;
struct lttng_payload_view header_view =
lttng_payload_view_from_view(view, 0, sizeof(*header));
switch ((enum lttng_error_query_target_type) header->target_type) {
case LTTNG_ERROR_QUERY_TARGET_TYPE_TRIGGER:
{
- struct lttng_trigger *trigger;
ssize_t trigger_used_size;
struct lttng_payload_view trigger_view =
lttng_payload_view_from_view(
used_size += trigger_used_size;
*query = lttng_error_query_trigger_create(trigger);
- lttng_trigger_put(trigger);
if (!*query) {
used_size = -1;
goto end;
}
case LTTNG_ERROR_QUERY_TARGET_TYPE_ACTION:
{
- struct lttng_trigger *trigger;
const struct lttng_action *target_action;
ssize_t trigger_used_size;
struct lttng_error_query_action_comm *action_header;
*query = lttng_error_query_action_create(
trigger, target_action);
- lttng_trigger_put(trigger);
if (!*query) {
used_size = -1;
goto end;
}
end:
+ lttng_trigger_put(trigger);
return used_size;
}