diff options
author | Gregory Nutt <gnutt@nuttx.org> | 2014-02-25 16:41:11 -0600 |
---|---|---|
committer | Gregory Nutt <gnutt@nuttx.org> | 2014-02-25 16:41:11 -0600 |
commit | 9dcce886a413a43def88b254eaad545bd16e9f9d (patch) | |
tree | b8d2499845460fe217e06e0d29e7045f8aec4ffd /nuttx/net/net_close.c | |
parent | d56d58f94575ce871558a43dd01b73c4d976bbfe (diff) | |
download | px4-nuttx-9dcce886a413a43def88b254eaad545bd16e9f9d.tar.gz px4-nuttx-9dcce886a413a43def88b254eaad545bd16e9f9d.tar.bz2 px4-nuttx-9dcce886a413a43def88b254eaad545bd16e9f9d.zip |
networking: Fix one place where the reference count was not being zeroed. This is really a cosmetic fix UNLESS CONFIG_DEBUG_NET is enabled, then it causes assertions
Diffstat (limited to 'nuttx/net/net_close.c')
-rw-r--r-- | nuttx/net/net_close.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/nuttx/net/net_close.c b/nuttx/net/net_close.c index 7bec9237c..9e3b7c50a 100644 --- a/nuttx/net/net_close.c +++ b/nuttx/net/net_close.c @@ -447,6 +447,7 @@ int psock_close(FAR struct socket *psock) /* Yes... then perform the disconnection now */ uip_unlisten(conn); /* No longer accepting connections */ + conn->crefs = 0; /* Discard our reference to the connection */ err = netclose_disconnect(psock); /* Break any current connections */ if (err < 0) { |