Throw error when error happens in the tcp_listen function
This commit is contained in:
parent
cfea8adacb
commit
4c163cf43b
@ -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;
|
||||
|
Loading…
Reference in New Issue
Block a user