mirror of
https://github.com/esphome/esphome.git
synced 2026-09-18 10:38:38 +00:00
restore removed comments in register/unregister_socket_fd
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Opus 4.6
parent
52cc24880c
commit
f160a17617
@@ -583,6 +583,7 @@ void Application::unregister_socket(struct lwip_sock *sock) {
|
||||
#elif defined(USE_SOCKET_SELECT_SUPPORT)
|
||||
bool Application::register_socket_fd(int fd) {
|
||||
// WARNING: This function is NOT thread-safe and must only be called from the main loop
|
||||
// It modifies socket_fds_ and related variables without locking
|
||||
if (fd < 0)
|
||||
return false;
|
||||
|
||||
@@ -608,6 +609,7 @@ bool Application::register_socket_fd(int fd) {
|
||||
|
||||
void Application::unregister_socket_fd(int fd) {
|
||||
// WARNING: This function is NOT thread-safe and must only be called from the main loop
|
||||
// It modifies socket_fds_ and related variables without locking
|
||||
if (fd < 0)
|
||||
return;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user