X-Git-Url: https://git.lttng.org/?p=lttng-tools.git;a=blobdiff_plain;f=tests%2Fregression%2Ftools%2Fnotification%2Fnotification.c;fp=tests%2Fregression%2Ftools%2Fnotification%2Fnotification.c;h=c097c102698d88871a3c089a8d5558324a9be2b3;hp=ce6f5633275bd05f78df5a05d680919d18ee6276;hb=0efb2ad7fc448283184e43d6fb0915febae45384;hpb=94dbd8e4ed88cd56829159e1fef374a16fddd593 diff --git a/tests/regression/tools/notification/notification.c b/tests/regression/tools/notification/notification.c index ce6f56332..c097c1026 100644 --- a/tests/regression/tools/notification/notification.c +++ b/tests/regression/tools/notification/notification.c @@ -590,7 +590,13 @@ static const char *get_notification_trigger_name( } trigger_status = lttng_trigger_get_name(trigger, &trigger_name); - if (trigger_status != LTTNG_TRIGGER_STATUS_OK) { + switch (trigger_status) { + case LTTNG_TRIGGER_STATUS_OK: + break; + case LTTNG_TRIGGER_STATUS_UNSET: + trigger_name = "(anonymous)"; + break; + default: fail("Failed to get name from notification's trigger"); goto end; }