From 36f55f1f857f84c3ca88664b8050853e15350ade Mon Sep 17 00:00:00 2001 From: Martijn Dekker Date: Sun, 19 Jul 2020 06:42:53 +0100 Subject: [PATCH] bltins/whence.c: Revert accidentally included test (re: 3613da42) Some temp debug code that tests a possible fix for #26 accidentally snuck in to a completely unrelated commit. Sorry about that. --- src/cmd/ksh93/bltins/whence.c | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/src/cmd/ksh93/bltins/whence.c b/src/cmd/ksh93/bltins/whence.c index 1b1a80885..35b09aeed 100644 --- a/src/cmd/ksh93/bltins/whence.c +++ b/src/cmd/ksh93/bltins/whence.c @@ -190,10 +190,7 @@ static int whence(Shell_t *shp,char **argv, register int flags) if(flags&V_FLAG) { if(nv_isnull(np)) -{ -errormsg(SH_DICT,ERROR_warn(0),"[DEBUG] is_ufunction ONE: %s", name); cp = sh_translate(is_ufunction); -} else if(is_abuiltin(np)) { if(nv_isattr(np,BLT_SPC)) @@ -253,11 +250,8 @@ errormsg(SH_DICT,ERROR_warn(0),"[DEBUG] is_ufunction ONE: %s", name); const char *command_path = np->nvalue.pathcomp->name; sfprintf(sfstdout,"%s %s %s/%s\n",name,sh_translate(is_talias),command_path,cp); } - else if(np && nv_isnull(np)) -{ -errormsg(SH_DICT,ERROR_warn(0),"[DEBUG] is_ufunction TWO: %s", name); + else if(!np || nv_isnull(np)) sfprintf(sfstdout,"%s%s\n",name,sh_translate(is_ufunction)); -} continue; } sfputr(sfstdout,sh_fmtq(name),' ');