From 6ff206e057d46095bb21aa943c383bc76cd15036 Mon Sep 17 00:00:00 2001 From: Oliver Kiddle Date: Mon, 15 May 2000 00:31:20 +0000 Subject: Add -L option to the hash builtin --- Src/hashtable.c | 14 ++++++++++++++ 1 file changed, 14 insertions(+) (limited to 'Src/hashtable.c') diff --git a/Src/hashtable.c b/Src/hashtable.c index 917bbc9e6..9a1010ec6 100644 --- a/Src/hashtable.c +++ b/Src/hashtable.c @@ -734,6 +734,13 @@ printcmdnamnode(HashNode hn, int printflags) return; } + if (printflags & PRINT_LIST) { + printf("hash "); + + if(cn->nam[0] == '-') + printf("-- "); + } + if (cn->flags & HASHED) { quotedzputs(cn->nam, stdout); putchar('='); @@ -1371,6 +1378,13 @@ printnameddirnode(HashNode hn, int printflags) putchar('\n'); return; } + + if (printflags & PRINT_LIST) { + printf("hash -d "); + + if(nd->nam[0] == '-') + printf("-- "); + } quotedzputs(nd->nam, stdout); putchar('='); -- cgit 1.4.1