diff options
author | Ron Yorston <rmy@pobox.com> | 2017-07-29 10:03:45 +0100 |
---|---|---|
committer | Ron Yorston <rmy@pobox.com> | 2017-07-29 10:03:45 +0100 |
commit | bf35303101df45b43188bacf80840034aef40c45 (patch) | |
tree | b070fe5877d548ca604cab38028f71f62bc1210e /libbb | |
parent | 86d60bb0ceb277e500a8daabd995bc713bbdadc9 (diff) | |
download | busybox-w32-bf35303101df45b43188bacf80840034aef40c45.tar.gz busybox-w32-bf35303101df45b43188bacf80840034aef40c45.tar.bz2 busybox-w32-bf35303101df45b43188bacf80840034aef40c45.zip |
ash: remove old code to tab-complete 'busybox' in standalone shell
Diffstat (limited to 'libbb')
-rw-r--r-- | libbb/lineedit.c | 12 |
1 files changed, 2 insertions, 10 deletions
diff --git a/libbb/lineedit.c b/libbb/lineedit.c index a28b6ef98..a93e28975 100644 --- a/libbb/lineedit.c +++ b/libbb/lineedit.c | |||
@@ -680,14 +680,6 @@ static void add_match(char *matched) | |||
680 | num_matches++; | 680 | num_matches++; |
681 | } | 681 | } |
682 | 682 | ||
683 | #if ENABLE_FEATURE_SH_STANDALONE && NUM_APPLETS != 1 | ||
684 | static void add_partial_match(const char *part, const char *full, int plen) | ||
685 | { | ||
686 | if (strncmp(part, full, plen) == 0) | ||
687 | add_match(xstrdup(full)); | ||
688 | } | ||
689 | #endif | ||
690 | |||
691 | # if ENABLE_FEATURE_USERNAME_COMPLETION | 683 | # if ENABLE_FEATURE_USERNAME_COMPLETION |
692 | /* Replace "~user/..." with "/homedir/...". | 684 | /* Replace "~user/..." with "/homedir/...". |
693 | * The parameter is malloced, free it or return it | 685 | * The parameter is malloced, free it or return it |
@@ -839,11 +831,11 @@ static NOINLINE unsigned complete_cmd_dir_file(const char *command, int type) | |||
839 | const char *p = applet_names; | 831 | const char *p = applet_names; |
840 | 832 | ||
841 | while (*p) { | 833 | while (*p) { |
842 | add_partial_match(pfind, p, pf_len); | 834 | if (strncmp(pfind, p, pf_len) == 0) |
835 | add_match(xstrdup(p)); | ||
843 | while (*p++ != '\0') | 836 | while (*p++ != '\0') |
844 | continue; | 837 | continue; |
845 | } | 838 | } |
846 | add_partial_match(pfind, "busybox", pf_len); | ||
847 | } | 839 | } |
848 | # endif | 840 | # endif |
849 | 841 | ||