summaryrefslogtreecommitdiffstats
path: root/bin
diff options
context:
space:
mode:
authortjr <tjr@FreeBSD.org>2002-06-13 07:50:50 +0000
committertjr <tjr@FreeBSD.org>2002-06-13 07:50:50 +0000
commit08e98db385e632c06fd36a487b2112e0ccaa1306 (patch)
tree7a8f508b26cb60fff758b269bbaf5441de6f1811 /bin
parent0fa62227284c11a4344e57f637445607c5dc8ff3 (diff)
downloadFreeBSD-src-08e98db385e632c06fd36a487b2112e0ccaa1306.zip
FreeBSD-src-08e98db385e632c06fd36a487b2112e0ccaa1306.tar.gz
Don't list shell builtins when the hash command is used (SUSv3)
Diffstat (limited to 'bin')
-rw-r--r--bin/sh/exec.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/bin/sh/exec.c b/bin/sh/exec.c
index 718ef82..c503617 100644
--- a/bin/sh/exec.c
+++ b/bin/sh/exec.c
@@ -336,7 +336,8 @@ hashcmd(int argc __unused, char **argv __unused)
if (*argptr == NULL) {
for (pp = cmdtable ; pp < &cmdtable[CMDTABLESIZE] ; pp++) {
for (cmdp = *pp ; cmdp ; cmdp = cmdp->next) {
- printentry(cmdp, verbose);
+ if (cmdp->cmdtype == CMDNORMAL)
+ printentry(cmdp, verbose);
}
}
return 0;
OpenPOWER on IntegriCloud