mirror of
https://github.com/espressif/ESP8266_RTOS_SDK.git
synced 2025-07-15 08:32:42 +08:00
fix(LWIP): Fix close same socket many times
This commit is contained in:
@ -1012,12 +1012,14 @@ int lwip_close(int s)
|
||||
sys_mutex_t lock_tmp[SOCK_MT_LOCK_MAX];
|
||||
|
||||
#ifdef SOCKETS_MT_DISABLE_SHUTDOWN
|
||||
LWIP_ENTER_MT(s, SOCK_MT_CLOSE, 0);
|
||||
|
||||
lwip_sync_mt(s, SHUT_RDWR);
|
||||
#else
|
||||
lwip_shutdown(s, SHUT_RDWR);
|
||||
#endif
|
||||
|
||||
LWIP_ENTER_MT(s, SOCK_MT_CLOSE, 0);
|
||||
#endif
|
||||
|
||||
ret = lwip_close_esp(s);
|
||||
|
||||
|
Reference in New Issue
Block a user