From 3fd43c488b47874db22a87a1d87eed94bbd85725 Mon Sep 17 00:00:00 2001 From: Garrett D'Amore Date: Sun, 1 Jan 2017 14:34:29 -0800 Subject: Pipe simplifications for thread management. This may also address a race in closing down pipes. Now pipes are always registered with the socket. They also always have both a sender and receiver thread. If the protocol doesn't need one or the other, the stock thread just exits early. --- src/core/pipe.h | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) (limited to 'src/core/pipe.h') diff --git a/src/core/pipe.h b/src/core/pipe.h index d12320b2..3c2c1166 100644 --- a/src/core/pipe.h +++ b/src/core/pipe.h @@ -27,13 +27,8 @@ struct nng_pipe { nni_endpt * p_ep; int p_reap; int p_active; - int p_abort; - nni_mutex p_mx; - nni_cond p_cv; - void (*p_send)(void *); - void (*p_recv)(void *); - nni_thread * p_send_thr; - nni_thread * p_recv_thr; + nni_thr p_send_thr; + nni_thr p_recv_thr; }; // Pipe operations that protocols use. -- cgit v1.2.3-70-g09d2