Skip to content

Commit

Permalink
Forgot to unassociate event on cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
ktakashi committed Dec 11, 2024
1 parent a49f1b4 commit 1ff0ade
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion ext/socket/selector-win.c
Original file line number Diff line number Diff line change
Expand Up @@ -168,7 +168,10 @@ SgObject Sg_SocketSelectorWait(SgSocketSelector *selector, SgObject timeout)

cleanup:
for (int i = 0; i < n; i++) {
if (eArray[i]) WSACloseEvent(eArray[i]);
if (eArray[i]) {
WSAEventSelect(sArray[i], eArray[i], 0);
WSACloseEvent(eArray[i]);
}
}
ctx->thread = NULL;
if (err) {
Expand Down

0 comments on commit 1ff0ade

Please sign in to comment.