From 4961d1d6bdd9c178953e68043e7d7676a69bf8e4 Mon Sep 17 00:00:00 2001 From: rswindell <> Date: Tue, 30 Apr 2002 23:38:23 +0000 Subject: [PATCH] uifcinic() calls uifcbail before returning error. --- src/uifc/uifcc.c | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) diff --git a/src/uifc/uifcc.c b/src/uifc/uifcc.c index ffd8312772..d1577782e8 100644 --- a/src/uifc/uifcc.c +++ b/src/uifc/uifcc.c @@ -193,11 +193,13 @@ int uifcinic(uifcapi_t* uifcapi) api->scrn_len=height; if(api->scrn_len<MIN_LINES || api->scrn_len>MAX_LINES) { + uifcbail(); fprintf(stderr,"\7UIFC: Screen length (%u) must be between %d and %d lines\n" ,api->scrn_len,MIN_LINES,MAX_LINES); return(-2); } if(width*height*2>MAX_BFLN) { + uifcbail(); fprintf(stderr,"\7UIFC: Screen size (%u x %u) must be smaller than %u\n" ,api->scrn_len,width,height,(uchar)(MAX_BFLN/2)); return(-2); @@ -207,6 +209,7 @@ int uifcinic(uifcapi_t* uifcapi) if(width<80) { + uifcbail(); fprintf(stderr,"\7UIFC: Screen width (%u) must be at least 80 characters\n" ,width); return(-3); @@ -290,12 +293,12 @@ static void showmouse(void) void uifcbail(void) { -curs_set(1); -clear(); -nl(); -nocbreak(); -refresh(); -endwin(); + curs_set(1); + clear(); + nl(); + nocbreak(); + refresh(); + endwin(); } /****************************************************************************/ -- GitLab