SetWindowText(hwnd, "PuTTY (inactive)");
set_icon(NULL, "PuTTY (inactive)"); set_title(NULL, "PuTTY (inactive)");
static void enact_pending_netevent(void){    static int reentering = 0;    extern int select_result(WPARAM, LPARAM);    int ret;    if (reentering)	return;			       /* don't unpend the pending */    pending_netevent = FALSE;    reentering = 1;    ret = select_result(pend_netevent_wParam, pend_netevent_lParam);    reentering = 0;    if (ret == 0 && !session_closed) {	/* Abnormal exits will already have set session_closed and taken	 * appropriate action. */	if (cfg.close_on_exit == COE_ALWAYS ||	    cfg.close_on_exit == COE_NORMAL) PostQuitMessage(0);	else {	    session_closed = TRUE;	    SetWindowText(hwnd, "PuTTY (inactive)");	    MessageBox(hwnd, "Connection closed by remote host",		       "PuTTY", MB_OK | MB_ICONINFORMATION);	}    }}