Bah, don't fix what isn't broken
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1158 35c25a1d-7b9e-4130-9fde-d3aeb78583b8master
parent
6ca01b1cd8
commit
9b4055c4da
|
@ -22,8 +22,6 @@ CVS code -
|
||||||
- Change input var to one char instead of array (David Benbennick).
|
- Change input var to one char instead of array (David Benbennick).
|
||||||
- Move NO_CONVERT check up so chars get read in properly (DLR).
|
- Move NO_CONVERT check up so chars get read in properly (DLR).
|
||||||
- nano.c:
|
- nano.c:
|
||||||
- Move the termios things in main() up to signal_init(), where
|
|
||||||
they should probably be anyway.
|
|
||||||
do_justify()
|
do_justify()
|
||||||
- More fixes for indented justify (David Benbennick).
|
- More fixes for indented justify (David Benbennick).
|
||||||
do_int_speller()
|
do_int_speller()
|
||||||
|
|
24
nano.c
24
nano.c
|
@ -2038,12 +2038,7 @@ void signal_init(void)
|
||||||
|
|
||||||
|
|
||||||
#ifdef _POSIX_VDISABLE
|
#ifdef _POSIX_VDISABLE
|
||||||
tcgetattr(0, &oldterm);
|
tcgetattr(0, &term);
|
||||||
|
|
||||||
term = oldterm;
|
|
||||||
term.c_cc[VINTR] = _POSIX_VDISABLE;
|
|
||||||
term.c_cc[VQUIT] = _POSIX_VDISABLE;
|
|
||||||
term.c_lflag &= ~IEXTEN;
|
|
||||||
|
|
||||||
#ifdef VDSUSP
|
#ifdef VDSUSP
|
||||||
term.c_cc[VDSUSP] = _POSIX_VDISABLE;
|
term.c_cc[VDSUSP] = _POSIX_VDISABLE;
|
||||||
|
@ -2738,6 +2733,10 @@ int main(int argc, char *argv[])
|
||||||
toggle *t;
|
toggle *t;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#ifdef _POSIX_VDISABLE
|
||||||
|
struct termios term;
|
||||||
|
#endif
|
||||||
|
|
||||||
#ifdef HAVE_GETOPT_LONG
|
#ifdef HAVE_GETOPT_LONG
|
||||||
int option_index = 0;
|
int option_index = 0;
|
||||||
struct option long_options[] = {
|
struct option long_options[] = {
|
||||||
|
@ -2976,7 +2975,17 @@ int main(int argc, char *argv[])
|
||||||
filename = mallocstrcpy(filename, argv[optind]);
|
filename = mallocstrcpy(filename, argv[optind]);
|
||||||
}
|
}
|
||||||
|
|
||||||
signal_init();
|
|
||||||
|
/* First back up the old settings so they can be restored, duh */
|
||||||
|
tcgetattr(0, &oldterm);
|
||||||
|
|
||||||
|
#ifdef _POSIX_VDISABLE
|
||||||
|
term = oldterm;
|
||||||
|
term.c_cc[VINTR] = _POSIX_VDISABLE;
|
||||||
|
term.c_cc[VQUIT] = _POSIX_VDISABLE;
|
||||||
|
term.c_lflag &= ~IEXTEN;
|
||||||
|
tcsetattr(0, TCSANOW, &term);
|
||||||
|
#endif
|
||||||
|
|
||||||
/* now ncurses init stuff... */
|
/* now ncurses init stuff... */
|
||||||
initscr();
|
initscr();
|
||||||
|
@ -2992,6 +3001,7 @@ int main(int argc, char *argv[])
|
||||||
init_help_msg();
|
init_help_msg();
|
||||||
help_init();
|
help_init();
|
||||||
#endif
|
#endif
|
||||||
|
signal_init();
|
||||||
|
|
||||||
#ifdef DEBUG
|
#ifdef DEBUG
|
||||||
fprintf(stderr, _("Main: set up windows\n"));
|
fprintf(stderr, _("Main: set up windows\n"));
|
||||||
|
|
Loading…
Reference in New Issue