reentering = 0;
static void enact_pending_netevent(void) {    int i;    pending_netevent = FALSE;    i = back->msg (pend_netevent_wParam, pend_netevent_lParam);    if (i < 0) {	char buf[1024];	switch (WSABASEERR + (-i) % 10000) {	  case WSAECONNRESET:	    sprintf(buf, "Connection reset by peer");	    break;	  default:	    sprintf(buf, "Unexpected network error %d", -i);	    break;	}	MessageBox(hwnd, buf, "PuTTY Fatal Error",		   MB_ICONERROR | MB_OK);	PostQuitMessage(1);    } else if (i == 0) {	if (cfg.close_on_exit)	    PostQuitMessage(0);	else {	    session_closed = TRUE;	    MessageBox(hwnd, "Connection closed by remote host",		       "PuTTY", MB_OK | MB_ICONINFORMATION);	    SetWindowText (hwnd, "PuTTY (inactive)");	}    }}