Fix: perform TLS fixup in all UST entry points from each thread
[lttng-ust.git] / liblttng-ust / lttng-context-provider.c
index 6c067e2fecae06548a3d4495ef9477b2495a6a5b..e6749beeda6b42d4b8e0a267c1f555f18e1aaaa4 100644 (file)
@@ -67,6 +67,8 @@ int lttng_ust_context_provider_register(struct lttng_ust_context_provider *provi
        uint32_t hash;
        int ret = 0;
 
+       lttng_ust_fixup_tls();
+
        /* Provider name starts with "$app.". */
        if (strncmp("$app.", provider->name, strlen("$app.") != 0))
                return -EINVAL;
@@ -94,6 +96,8 @@ end:
 
 void lttng_ust_context_provider_unregister(struct lttng_ust_context_provider *provider)
 {
+       lttng_ust_fixup_tls();
+
        if (ust_lock())
                goto end;
        lttng_ust_context_set_session_provider(provider->name,
This page took 0.025241 seconds and 4 git commands to generate.