X-Git-Url: http://git.madism.org/?a=blobdiff_plain;f=lib-ui%2Fcurs_lib.c;h=c51f1a4dec99f207ac6fda487125f3fb781716a5;hb=152de0428ee8091729462107e260a247081c949f;hp=2203672748b2f7e90a5b7508744744de6bc71699;hpb=8b89861e79d1b2e8ddcc54ea4d89957d6d10ebe6;p=apps%2Fmadmutt.git diff --git a/lib-ui/curs_lib.c b/lib-ui/curs_lib.c index 2203672..c51f1a4 100644 --- a/lib-ui/curs_lib.c +++ b/lib-ui/curs_lib.c @@ -308,6 +308,10 @@ void mutt_show_error (void) void curses_initialize(void) { + if (initscr () == NULL) { + puts _("Error initializing terminal."); + exit (1); + } ci_start_color(); keypad(stdscr, true); cbreak(); @@ -316,12 +320,6 @@ void curses_initialize(void) meta(stdscr, true); } -void _mutt_perror (const char *s, const char* filename, int line) -{ - char *p = strerror (errno); - mutt_error ("%s: %s (errno = %d) from %s:%i", s, p ? p : _("unknown error"), errno, filename, line); -} - /* * prompts the user to enter a keystroke, and displays the octal value back * to the user.