X-Git-Url: https://git.lttng.org/?p=lttng-tools.git;a=blobdiff_plain;f=src%2Fbin%2Flttng-sessiond%2Faction-executor.c;h=bce7268e5bac05ccf695f5415d06447f2df1ee41;hp=86bada257634b90a8d0ebd7dc225732602b12e48;hb=c0e2990d32d1e55c783c7eb3299f23a7ce062270;hpb=52d55cf94968516273d6c67f2db428908def55ac diff --git a/src/bin/lttng-sessiond/action-executor.c b/src/bin/lttng-sessiond/action-executor.c index 86bada257..bce7268e5 100644 --- a/src/bin/lttng-sessiond/action-executor.c +++ b/src/bin/lttng-sessiond/action-executor.c @@ -95,22 +95,13 @@ static const action_executor_handler action_executors[] = { [LTTNG_ACTION_TYPE_GROUP] = action_executor_group_handler, }; -static const char *action_type_names[] = { - [LTTNG_ACTION_TYPE_NOTIFY] = "Notify", - [LTTNG_ACTION_TYPE_START_SESSION] = "Start session", - [LTTNG_ACTION_TYPE_STOP_SESSION] = "Stop session", - [LTTNG_ACTION_TYPE_ROTATE_SESSION] = "Rotate session", - [LTTNG_ACTION_TYPE_SNAPSHOT_SESSION] = "Snapshot session", - [LTTNG_ACTION_TYPE_GROUP] = "Group", -}; - static const char *get_action_name(const struct lttng_action *action) { const enum lttng_action_type action_type = lttng_action_get_type(action); assert(action_type != LTTNG_ACTION_TYPE_UNKNOWN); - return action_type_names[action_type]; + return lttng_action_type_string(action_type); } /* Check if this trigger allowed to interect with a given session. */ @@ -539,7 +530,8 @@ static void *action_executor_thread(void *_data) assert(executor); - health_register(health_sessiond, HEALTH_SESSIOND_TYPE_ACTION_EXECUTOR); + health_register(the_health_sessiond, + HEALTH_SESSIOND_TYPE_ACTION_EXECUTOR); rcu_register_thread(); rcu_thread_online(); @@ -592,7 +584,7 @@ static void *action_executor_thread(void *_data) rcu_thread_offline(); rcu_unregister_thread(); - health_unregister(health_sessiond); + health_unregister(the_health_sessiond); return NULL; }