diff options
| author | Garrett D'Amore <garrett@damore.org> | 2017-03-10 14:39:21 -0800 |
|---|---|---|
| committer | Garrett D'Amore <garrett@damore.org> | 2017-03-10 14:39:21 -0800 |
| commit | c436e174d0ed8c5dc14af060e994b97a83df7750 (patch) | |
| tree | 9eeb7ef18ad6eb1a975ab6aaa7a68bcd3ee81c9a /src/core/pipe.h | |
| parent | f5c259eec0cd3fa5cd623e159cbfec83b4a500d5 (diff) | |
| download | nng-c436e174d0ed8c5dc14af060e994b97a83df7750.tar.gz nng-c436e174d0ed8c5dc14af060e994b97a83df7750.tar.bz2 nng-c436e174d0ed8c5dc14af060e994b97a83df7750.zip | |
Start of close related race fixes. Scalability test.
Diffstat (limited to 'src/core/pipe.h')
| -rw-r--r-- | src/core/pipe.h | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/core/pipe.h b/src/core/pipe.h index 3ec4a7a3..6cabf4e7 100644 --- a/src/core/pipe.h +++ b/src/core/pipe.h @@ -28,7 +28,8 @@ struct nni_pipe { nni_ep * p_ep; int p_reap; int p_active; - nni_thr p_worker_thr[NNI_MAXWORKERS]; + nni_mtx p_mtx; + int p_refcnt; }; // AIO @@ -40,6 +41,8 @@ extern int nni_pipe_recv(nni_pipe *, nng_msg **); extern int nni_pipe_send(nni_pipe *, nng_msg *); extern uint32_t nni_pipe_id(nni_pipe *); extern void nni_pipe_close(nni_pipe *); +extern void nni_pipe_incref(nni_pipe *); +extern void nni_pipe_decref(nni_pipe *); // Used only by the socket core - as we don't wish to expose the details // of the pipe structure outside of pipe.c. |
