git-svn-id: svn://svn.savannah.gnu.org/nano/branches/nano_2_0_branch/nano@4198
35c25a1d-7b9e-4130-9fde-
d3aeb78583b8
(DLR, found by Paul Goins)
- Make sure the mark is always properly positioned after
uncutting text with the mark on. (DLR)
+ main()
+ - Exit if initscr() fails. (DLR)
- prompt.c:
do_yesno_prompt()
- Remove redundant check for NO_HELP's being FALSE. (DLR)
free(backup_dir);
backup_dir = backup_dir_cpy;
}
-#endif
+#endif
#ifndef DISABLE_JUSTIFY
if (quotestr_cpy != NULL) {
free(quotestr);
/* Back up the old terminal settings so that they can be restored. */
tcgetattr(0, &oldterm);
- /* Initialize curses mode. */
- initscr();
+ /* Initialize curses mode. If this fails, get out. */
+ if (initscr() == NULL)
+ exit(1);
/* Set up the terminal state. */
terminal_init();