diff options
Diffstat (limited to 'bin/ksh/exec.c')
-rw-r--r-- | bin/ksh/exec.c | 29 |
1 files changed, 1 insertions, 28 deletions
diff --git a/bin/ksh/exec.c b/bin/ksh/exec.c index 887f6f95a9b..69a1cb97b91 100644 --- a/bin/ksh/exec.c +++ b/bin/ksh/exec.c @@ -1,4 +1,4 @@ -/* $OpenBSD: exec.c,v 1.76 2022/10/10 14:57:48 kn Exp $ */ +/* $OpenBSD: exec.c,v 1.77 2023/06/21 22:22:08 millert Exp $ */ /* * execute command tree @@ -1340,33 +1340,6 @@ pr_menu(char *const *ap) return n; } -/* XXX: horrible kludge to fit within the framework */ - -static char *plain_fmt_entry(void *arg, int i, char *buf, int buflen); - -static char * -plain_fmt_entry(void *arg, int i, char *buf, int buflen) -{ - shf_snprintf(buf, buflen, "%s", ((char *const *)arg)[i]); - return buf; -} - -int -pr_list(char *const *ap) -{ - char *const *pp; - int nwidth; - int i, n; - - for (n = 0, nwidth = 0, pp = ap; *pp; n++, pp++) { - i = strlen(*pp); - nwidth = (i > nwidth) ? i : nwidth; - } - print_columns(shl_out, n, plain_fmt_entry, (void *) ap, nwidth + 1, 0); - - return n; -} - /* * [[ ... ]] evaluation routines */ |