X-Git-Url: http://git.lttng.org./?a=blobdiff_plain;f=include%2Flttng%2Ftracepoint.h;h=39f2c4db752342f14c5bd8206174093595ebacec;hb=cfbdb7732a22a21b2803a7aed6962d72bef54f5a;hp=a73056030d0be4c3dc12b06035bf18191d649f95;hpb=32855a09dc8925f578624cab645a33ecb139389c;p=lttng-ust.git diff --git a/include/lttng/tracepoint.h b/include/lttng/tracepoint.h index a7305603..39f2c4db 100644 --- a/include/lttng/tracepoint.h +++ b/include/lttng/tracepoint.h @@ -241,8 +241,6 @@ static inline void tracepoint_disable_destructors(void) __tracepoints__disable_destructors = 1; } -#if defined(TRACEPOINT_DEFINE) || defined(TRACEPOINT_CREATE_PROBES) - /* * These weak symbols, the constructor, and destructor take care of * registering only _one_ instance of the tracepoints per shared-ojbect @@ -309,8 +307,12 @@ __tracepoints__init(void); static void __tracepoints__init(void) { - if (__tracepoint_registered++) + if (__tracepoint_registered++) { + if (!tracepoint_dlopen_ptr->liblttngust_handle) + return; + __tracepoint__init_urcu_sym(); return; + } if (!tracepoint_dlopen_ptr) tracepoint_dlopen_ptr = &tracepoint_dlopen; @@ -345,8 +347,6 @@ __tracepoints__destroy(void) } } -#endif - #ifdef TRACEPOINT_DEFINE /*