trigger: generate and add tracer token on registration
[lttng-tools.git] / src / common / trigger.c
index af0c5fa348166b833c61331f19f2cc2dba69567d..f77a321295d4c10a9c7d67ce51071bc649854a19 100644 (file)
@@ -395,6 +395,22 @@ end:
        return ret;
 }
 
+LTTNG_HIDDEN
+void lttng_trigger_set_tracer_token(struct lttng_trigger *trigger,
+               uint64_t token)
+{
+       assert(trigger);
+       LTTNG_OPTIONAL_SET(&trigger->tracer_token, token);
+}
+
+LTTNG_HIDDEN
+uint64_t lttng_trigger_get_tracer_token(const struct lttng_trigger *trigger)
+{
+       assert(trigger);
+
+       return LTTNG_OPTIONAL_GET(trigger->tracer_token);
+}
+
 LTTNG_HIDDEN
 int lttng_trigger_generate_name(struct lttng_trigger *trigger,
                uint64_t unique_id)
This page took 0.030485 seconds and 4 git commands to generate.