Skip to content
Snippets Groups Projects
Commit b6fe381f authored by Deucе's avatar Deucе :ok_hand_tone4:
Browse files

Fix console and connect events when using select()

parent baa72abe
No related branches found
No related tags found
1 merge request!463MRC mods by Codefenix (2024-10-20)
Pipeline #2274 passed
...@@ -1330,7 +1330,7 @@ js_handle_events(JSContext *cx, js_callback_t *cb, volatile int *terminated) ...@@ -1330,7 +1330,7 @@ js_handle_events(JSContext *cx, js_callback_t *cb, volatile int *terminated)
#ifdef PREFER_POLL #ifdef PREFER_POLL
if (fds[cfd].revents & ~(POLLOUT | POLLWRNORM | POLLWRBAND)) { if (fds[cfd].revents & ~(POLLOUT | POLLWRNORM | POLLWRBAND)) {
#else #else
if (FD_ISSET(ev->data.connect.sv[0], &wfds)) { if (FD_ISSET(ev->data.connect.sv[0], &rfds)) {
#endif #endif
closesocket(ev->data.connect.sv[0]); closesocket(ev->data.connect.sv[0]);
break; break;
...@@ -1343,7 +1343,7 @@ js_handle_events(JSContext *cx, js_callback_t *cb, volatile int *terminated) ...@@ -1343,7 +1343,7 @@ js_handle_events(JSContext *cx, js_callback_t *cb, volatile int *terminated)
#ifdef PREFER_POLL #ifdef PREFER_POLL
if (fds[cfd].revents & ~(POLLOUT | POLLWRNORM | POLLWRBAND)) { if (fds[cfd].revents & ~(POLLOUT | POLLWRNORM | POLLWRBAND)) {
#else #else
if (FD_ISSET(ev->data.sock, &wfds)) { if (FD_ISSET(ev->data.sock, &rfds)) {
#endif #endif
break; break;
} }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment