You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@nuttx.apache.org by ma...@apache.org on 2022/10/14 03:29:30 UTC
[incubator-nuttx] 03/03: usrsock: combine response and events when socket setup case
This is an automated email from the ASF dual-hosted git repository.
masayuki pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-nuttx.git
commit 403c657f4281ce737040d0323aada7d1b7a0e34b
Author: zhanghongyu <zh...@xiaomi.com>
AuthorDate: Sat Oct 8 11:24:10 2022 +0800
usrsock: combine response and events when socket setup case
Signed-off-by: zhanghongyu <zh...@xiaomi.com>
---
net/usrsock/usrsock_socket.c | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/net/usrsock/usrsock_socket.c b/net/usrsock/usrsock_socket.c
index 18c205a74a..bc454fd0b3 100644
--- a/net/usrsock/usrsock_socket.c
+++ b/net/usrsock/usrsock_socket.c
@@ -79,6 +79,10 @@ static uint16_t socket_event(FAR struct net_driver_s *dev,
conn->state = USRSOCK_CONN_STATE_READY;
conn->usockid = pstate->result;
+ if (flags & USRSOCK_EVENT_SENDTO_READY)
+ {
+ conn->flags |= USRSOCK_EVENT_SENDTO_READY;
+ }
}
/* Stop further callbacks */