diff options
author | Dimitri Staessens <dimitri.staessens@ugent.be> | 2017-11-29 20:11:44 +0100 |
---|---|---|
committer | Sander Vrijders <sander.vrijders@ugent.be> | 2017-11-29 20:12:46 +0100 |
commit | 7c64a1df4ed4c3d001d03b4ec3c4e84638a12d86 (patch) | |
tree | caed7f7dfcd2ca874ad214b50584378d51c410f6 /src/lib | |
parent | cff56ac00e82c001659f54a61942ec55dac13268 (diff) | |
download | ouroboros-7c64a1df4ed4c3d001d03b4ec3c4e84638a12d86.tar.gz ouroboros-7c64a1df4ed4c3d001d03b4ec3c4e84638a12d86.zip |
ipcpd, irmd: Bugfix for failed accept() calls
The ipcp will not have the rx_rb set for a pending flow, so it should
not call shm_rbuff_fini. The irmd should not call ipcp_flow_dealloc
for flows that are still pending flow allocation.
Signed-off-by: Dimitri Staessens <dimitri.staessens@ugent.be>
Signed-off-by: Sander Vrijders <sander.vrijders@ugent.be>
Diffstat (limited to 'src/lib')
-rw-r--r-- | src/lib/dev.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/lib/dev.c b/src/lib/dev.c index 3c81d1db..a577ca80 100644 --- a/src/lib/dev.c +++ b/src/lib/dev.c @@ -1369,7 +1369,8 @@ void ipcp_flow_fini(int fd) pthread_rwlock_unlock(&ai.lock); - shm_rbuff_fini(rx_rb); + if (rx_rb != NULL) + shm_rbuff_fini(rx_rb); } int ipcp_flow_get_qoscube(int fd, |