*
* ust_lock nests within the dynamic loader lock (within glibc) because
* it is taken within the library constructor.
+ *
+ * The ust fd tracker lock nests within the ust_mutex.
*/
static pthread_mutex_t ust_mutex = PTHREAD_MUTEX_INITIALIZER;
sock_info->registration_done = 1;
decrement_sem_count(1);
+ if (!sock_info->statedump_pending) {
+ sock_info->initial_statedump_done = 1;
+ decrement_sem_count(1);
+ }
return 0;
}
long timeout;
lttng_ust_fixup_tls();
+ lttng_ust_fd_tracker_register_thread();
/*
* If available, add '-ust' to the end of this thread's
* process name
ust_lock_nocheck();
urcu_bp_before_fork();
+ lttng_ust_lock_fd_tracker();
}
static void ust_after_fork_common(sigset_t *restore_sigset)
int ret;
DBG("process %d", getpid());
+ lttng_ust_unlock_fd_tracker();
ust_unlock();
pthread_mutex_unlock(&ust_fork_mutex);