mirror of
https://github.com/apache/nuttx.git
synced 2026-06-04 23:03:27 +08:00
Merged in rtakacs/nuttx/fix_tcp_listen (pull request #409)
Throw error when error happens in the tcp_listen function Approved-by: Gregory Nutt <gnutt@nuttx.org>
This commit is contained in:
+7
-1
@@ -151,7 +151,13 @@ int psock_listen(FAR struct socket *psock, int backlog)
|
||||
* accept() is called and enables poll()/select() logic.
|
||||
*/
|
||||
|
||||
tcp_listen(conn);
|
||||
errcode = tcp_listen(conn);
|
||||
|
||||
if (errcode < 0)
|
||||
{
|
||||
errcode = -errcode;
|
||||
goto errout;
|
||||
}
|
||||
#else
|
||||
errcode = EOPNOTSUPP;
|
||||
goto errout;
|
||||
|
||||
Reference in New Issue
Block a user