diff options
| author | geniusgogo <[email protected]> | 2023-02-24 21:02:04 +0800 |
|---|---|---|
| committer | guo <[email protected]> | 2023-02-25 17:07:20 +0800 |
| commit | 53afeda538b381bba1eb17950d3afb3e82476940 (patch) | |
| tree | 7aa90df12733d5231f26272474296c37b64f3359 /components | |
| parent | d3553e7220fd410b3e2d7635ab5a74ca45436e1d (diff) | |
fix inet_ioctlsocket set O_LARGEFILE flag by musl.
Diffstat (limited to 'components')
| -rw-r--r-- | components/net/sal/impl/af_inet_lwip.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/components/net/sal/impl/af_inet_lwip.c b/components/net/sal/impl/af_inet_lwip.c index 401b9001e4..db1d3f78b3 100644 --- a/components/net/sal/impl/af_inet_lwip.c +++ b/components/net/sal/impl/af_inet_lwip.c @@ -225,11 +225,14 @@ static int inet_getsockname(int socket, struct sockaddr *name, socklen_t *namele int inet_ioctlsocket(int socket, long cmd, void *arg) { + int flags; switch (cmd) { case F_GETFL: case F_SETFL: - return lwip_fcntl(socket, cmd, (int)(size_t)arg); + flags = (int)(size_t)arg; + flags &= ~O_LARGEFILE; + return lwip_fcntl(socket, cmd, flags); default: return lwip_ioctl(socket, cmd, arg); |
