c = LYgetch(); switch (TOUPPER(c)) {
c = LYgetch_single(); switch (c) {
PUBLIC int HTConfirmPostRedirect ARGS2(	CONST char *,	Redirecting_url,	int,		server_status){    int result = -1;    char *show_POST_url = NULL;    char *StatusInfo = 0;    char *url = 0;    int on_screen = 0;	/* 0 - show menu			 * 1 - show url			 * 2 - menu is already on screen */    if (server_status == 303 ||	server_status == 302) {	/*	 *  HTTP.c should not have called us for either of	 *  these because we're treating 302 as historical,	 *  so just return 303. - FM	 */	return 303;    }    if (dump_output_immediately) {	if (server_status == 301) {	    /*	    **	Treat 301 as historical, i.e., like 303 (GET	    **	without content), when not interactive. - FM	    */	    return 303;	} else {	    /*	    **	Treat anything else (e.g., 305, 306 or 307) as too	    **	dangerous to redirect without confirmation, and thus	    **	cancel when not interactive. - FM	    */	    return 0;	}    }    if (user_mode == NOVICE_MODE) {	on_screen = 2;	move(LYlines-2, 0);	HTSprintf0(&StatusInfo, SERVER_ASKED_FOR_REDIRECTION, server_status);	addstr(StatusInfo);	clrtoeol();	move(LYlines-1, 0);	HTSprintf0(&url, "URL: %.*s",		    (LYcols < 250 ? LYcols-6 : 250), Redirecting_url);	addstr(url);	clrtoeol();	if (server_status == 301) {	    _statusline(PROCEED_GET_CANCEL);	} else {	    _statusline(PROCEED_OR_CANCEL);	}    } else {	HTSprintf0(&StatusInfo, "%d %.*s",			    server_status,			    251,			    ((server_status == 301) ?			 ADVANCED_POST_GET_REDIRECT :			 ADVANCED_POST_REDIRECT));	StrAllocCopy(show_POST_url, LOCATION_HEADER);	StrAllocCat(show_POST_url, Redirecting_url);    }    while (result < 0) {	int c;	switch (on_screen) {	    case 0:		_statusline(StatusInfo);		break;	    case 1:		_statusline(show_POST_url);	}	c = LYgetch();	switch (TOUPPER(c)) {	    case 'P':		/*		**  Proceed with 301 or 307 redirect of POST		**  with same method and POST content. - FM		*/		FREE(show_POST_url);		result = 1;		break;	    case 7:	    case 'C':		/*		**  Cancel request.		*/		FREE(show_POST_url);		result = 0;		break;	    case 'U':		/*		**  Show URL for intermediate or advanced mode.		*/		if (user_mode != NOVICE_MODE) {		    if (on_screen == 1) {			on_screen = 0;		    } else {			on_screen = 1;		    }		}		break;	    case 'G':		if (server_status == 301) {		    /*		    **	Treat as 303 (GET without content).		    */		    FREE(show_POST_url);		    result = 303;		    break;		}		/* fall through to default */	    default:		/*		**  Get another character.		*/		if (on_screen == 1) {		    on_screen = 0;		} else {		    on_screen = 2;		}	}    }    FREE(StatusInfo);    FREE(url);    return (result);}