Don't exit silently, if initscr failed; put error message

This commit is contained in:
Andrey A. Chernov 1994-10-19 04:45:41 +00:00
parent e314eb04c7
commit 51c3256355
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=3716

View File

@ -99,8 +99,10 @@ void init_dialog(void)
exit(-1);
#endif
if (initscr() == NULL) /* Init curses */
if (initscr() == NULL) { /* Init curses */
fprintf(stderr, "\nCurses initialization error.\n");
exit(-1);
}
keypad(stdscr, TRUE);
cbreak();
noecho();