X-Git-Url: http://git.lttng.org./?a=blobdiff_plain;f=libust%2Ftracectl.c;h=d6726d4fc53290ffcd7d7b05cc6ed062d8d32e0a;hb=0b2026f29acabd8676db5272f9149769ecb18d69;hp=1dd71621e0e147ba471c97c02366de92171ccfea;hpb=ed1317e78616d3fb99791d4effef7473317c41ec;p=lttng-ust.git diff --git a/libust/tracectl.c b/libust/tracectl.c index 1dd71621..d6726d4f 100644 --- a/libust/tracectl.c +++ b/libust/tracectl.c @@ -804,12 +804,10 @@ void create_listener(void) void sighandler(int sig) { - static char have_listener = 0; DBG("sighandler"); if(!have_listener) { create_listener(); - have_listener = 1; } } @@ -1128,6 +1126,13 @@ static void __attribute__((destructor)) keepalive() ustcomm_fini_app(&ustcomm_app); } +void ust_potential_exec(void) +{ + trace_mark(ust, potential_exec, MARK_NOARGS); + + keepalive(); +} + /* Notify ust that there was a fork. This needs to be called inside * the new process, anytime a process whose memory is not shared with * the parent is created. If this function is not called, the events @@ -1148,6 +1153,8 @@ void ust_fork(void) /* Delete all blocked consumers */ list_for_each_entry(bc, &blocked_consumers, list) { + close(bc->fd_producer); + close(bc->fd_consumer); free(deletable_bc); deletable_bc = bc; list_del(&bc->list);