fix 'command -v' for "shell reserved words"

From: Martijn Dekker <martijn@inlv.org>

also adjust manpage accordingly
This commit is contained in:
tg
2015-07-05 17:50:40 +00:00
parent 0d5b514e63
commit 48af854117
2 changed files with 6 additions and 6 deletions

View File

@ -38,7 +38,7 @@
#endif
#endif
__RCSID("$MirOS: src/bin/mksh/funcs.c,v 1.274 2015/07/05 14:43:06 tg Exp $");
__RCSID("$MirOS: src/bin/mksh/funcs.c,v 1.275 2015/07/05 17:50:39 tg Exp $");
#if HAVE_KILLPG
/*
@ -538,7 +538,7 @@ c_whence(const char **wp)
uint32_t h = 0;
tp = NULL;
if ((iam_whence || vflag) && !pflag)
if (!pflag)
tp = ktsearch(&keywords, id, h = hash(id));
if (!tp && !pflag) {
tp = ktsearch(&aliases, id, h ? h : hash(id));