diff options
author | yalei wang <wylandrea@gmail.com> | 2018-10-09 09:36:57 +0000 |
---|---|---|
committer | Gerrit Code Review <gerrit@fd.io> | 2018-10-09 09:36:57 +0000 |
commit | 88ef84f0e10ff670c9465800193e42c8f6a5aa9f (patch) | |
tree | f644f0e68f7a700f79bb1a4e0699fdb058082098 /stacks/lwip_stack/src | |
parent | 1b06aff4070ea87fde4539230cb72eb45ecd1da2 (diff) | |
parent | c3607894647a6f5b28656d01db0ce2b7a473543b (diff) |
Merge "Fix: Enhance select to support LWIP"
Diffstat (limited to 'stacks/lwip_stack/src')
-rw-r--r-- | stacks/lwip_stack/src/sbr/sbr_protocol_api.h | 2 | ||||
-rw-r--r-- | stacks/lwip_stack/src/sbr/sbr_socket.c | 2 |
2 files changed, 3 insertions, 1 deletions
diff --git a/stacks/lwip_stack/src/sbr/sbr_protocol_api.h b/stacks/lwip_stack/src/sbr/sbr_protocol_api.h index 0eac1c4..95ca565 100644 --- a/stacks/lwip_stack/src/sbr/sbr_protocol_api.h +++ b/stacks/lwip_stack/src/sbr/sbr_protocol_api.h @@ -91,6 +91,8 @@ int sbr_init_protocol (); int sbr_fork_protocol (); sbr_fdopt *sbr_get_fdopt (int domain, int type, int protocol); void sbr_app_touch_in (void); /*app send its version info to nStackMain */ +int lwip_try_select (int fdsize, fd_set * fdread, fd_set * fdwrite, + fd_set * fderr, struct timeval *timeout); #ifdef __cplusplus /* *INDENT-OFF* */ diff --git a/stacks/lwip_stack/src/sbr/sbr_socket.c b/stacks/lwip_stack/src/sbr/sbr_socket.c index e088224..6f867ab 100644 --- a/stacks/lwip_stack/src/sbr/sbr_socket.c +++ b/stacks/lwip_stack/src/sbr/sbr_socket.c @@ -1065,7 +1065,7 @@ SBR_INTERCEPT (int, select, (int nfds, fd_set * readfd, fd_set * writefd, fd_set * exceptfd, struct timeval * timeout)) { - return -1; + return lwip_try_select (nfds, readfd, writefd, exceptfd, timeout); } SBR_INTERCEPT (unsigned int, ep_getevt, |