From c7b9f846d9d4062dea9eeaca7b15c0a8caf0c73d Mon Sep 17 00:00:00 2001 From: Ben Harris Date: Wed, 17 May 2017 23:02:14 +0100 Subject: [PATCH] windows: Fix control-flow error in select_result(). When making select_result() return void (a2fb1d9), I removed a "return" at the end of the FD_CLOSE case, causing a fallthrough into FD_ACCEPT with hilarious (segfaulting) consequences. Re-instate the "return". --- windows/winnet.c | 1 + 1 file changed, 1 insertion(+) diff --git a/windows/winnet.c b/windows/winnet.c index 0ec64a55..ea950bba 100644 --- a/windows/winnet.c +++ b/windows/winnet.c @@ -1765,6 +1765,7 @@ void select_result(WPARAM wParam, LPARAM lParam) plug_closing(s->plug, NULL, 0, 0); } } while (ret > 0); + return; case FD_ACCEPT: { #ifdef NO_IPV6