change undef/def MKSH_NOVI into 0/1 MKSH_S_NOVI flag (with more to come:

MKSH_S_EDIT for small (Emacs) editing mode, MKSH_S_FEAT for all the dis-
abled language features), which can be set to 0 despite MKSH_SMALL being
defined to re-enable the Vi command line editing mode (which I wouldn't,
but fits into the general mastermind scheme)
This commit is contained in:
tg
2009-09-24 17:15:33 +00:00
parent f00db85c98
commit 1dfb13b603
8 changed files with 31 additions and 27 deletions

6
misc.c
View File

@ -29,7 +29,7 @@
#include <grp.h>
#endif
__RCSID("$MirOS: src/bin/mksh/misc.c,v 1.123 2009/09/20 16:40:56 tg Exp $");
__RCSID("$MirOS: src/bin/mksh/misc.c,v 1.124 2009/09/24 17:15:32 tg Exp $");
#undef USE_CHVT
/* XXX conditions correct? */
@ -201,11 +201,11 @@ change_flag(enum sh_flag f, int what, unsigned int newval)
} else
#endif
if ((
#ifndef MKSH_NOVI
#if !MKSH_S_NOVI
f == FVI ||
#endif
f == FEMACS || f == FGMACS) && newval) {
#ifndef MKSH_NOVI
#if !MKSH_S_NOVI
Flag(FVI) =
#endif
Flag(FEMACS) = Flag(FGMACS) = 0;