diff options
| author | Dmitry Shifrin <apokriff@users.noreply.github.com> | 2023-02-06 02:45:26 +0300 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2023-02-05 19:45:26 -0400 |
| commit | a1bc737bcc84cda545d6ff3b432235f5f2414f97 (patch) | |
| tree | 2365e566da8d5def2d2aee5146c24e85cc484b57 /src | |
| parent | 1892e1d6d102d1fbd37e2c3bbb59dc35d81c8b33 (diff) | |
| download | nng-a1bc737bcc84cda545d6ff3b432235f5f2414f97.tar.gz nng-a1bc737bcc84cda545d6ff3b432235f5f2414f97.tar.bz2 nng-a1bc737bcc84cda545d6ff3b432235f5f2414f97.zip | |
src: sp: tcp: Finish receive aio on close (#1636)
Finish receive aio on tcp
pipe close
Diffstat (limited to 'src')
| -rw-r--r-- | src/sp/transport/tcp/tcp.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/sp/transport/tcp/tcp.c b/src/sp/transport/tcp/tcp.c index 1e2ef733..ee90c80d 100644 --- a/src/sp/transport/tcp/tcp.c +++ b/src/sp/transport/tcp/tcp.c @@ -361,6 +361,11 @@ tcptran_pipe_recv_cb(void *arg) goto recv_error; } + if (p->closed) { + rv = NNG_ECLOSED; + goto recv_error; + } + n = nni_aio_count(rxaio); nni_aio_iov_advance(rxaio, n); if (nni_aio_iov_count(rxaio) > 0) { |
