From: Pierre-Marc Fournier Date: Tue, 13 Oct 2009 21:13:49 +0000 (-0400) Subject: set the reader side of the buffer-ready pipe non-blocking (experimental) X-Git-Tag: v0.1~94 X-Git-Url: http://git.liburcu.org/?p=ust.git;a=commitdiff_plain;h=c378e5b330530ab716a1743a66d6ec9f4a2464f9 set the reader side of the buffer-ready pipe non-blocking (experimental) --- diff --git a/libust/relay.c b/libust/relay.c index 3259ade..a31cdf7 100644 --- a/libust/relay.c +++ b/libust/relay.c @@ -26,6 +26,7 @@ #include #include #include +#include //#include "list.h" #include "relay.h" #include "channels.h" @@ -1503,6 +1504,12 @@ static int ltt_relay_create_buffer(struct ltt_trace_struct *trace, ltt_buf->data_ready_fd_read = fds[0]; ltt_buf->data_ready_fd_write = fds[1]; + /* FIXME: do we actually need this? */ + result = fcntl(fds[0], F_SETFL, O_NONBLOCK); + if(result == -1) { + PERROR("fcntl"); + } + //ust// ltt_buf->commit_seq = malloc(sizeof(ltt_buf->commit_seq) * n_subbufs); //ust// if(!ltt_buf->commit_seq) { //ust// return -1;