aboutsummaryrefslogtreecommitdiff
path: root/libbb/lineedit.c
diff options
context:
space:
mode:
authorRon Yorston <rmy@pobox.com>2024-01-23 09:24:38 +0000
committerRon Yorston <rmy@pobox.com>2024-01-23 09:30:11 +0000
commit99de7009698d868c0d139133ed4fa445be8cae50 (patch)
tree4f6f18253f799b80ef26add546a40118eec8b193 /libbb/lineedit.c
parentd7c65f24a9f6cf61a1fc629d5d2d48cc64d5bc41 (diff)
downloadbusybox-w32-99de7009698d868c0d139133ed4fa445be8cae50.tar.gz
busybox-w32-99de7009698d868c0d139133ed4fa445be8cae50.tar.bz2
busybox-w32-99de7009698d868c0d139133ed4fa445be8cae50.zip
Fix POSIX build in standalone shell mode
The conditional compilation to control standalone shell mode was incorrect when building for POSIX. This hadn't been noticed before as it had only been tested in the default configuration where standalone shell mode is disabled.
Diffstat (limited to 'libbb/lineedit.c')
-rw-r--r--libbb/lineedit.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/libbb/lineedit.c b/libbb/lineedit.c
index 976a7d87d..13cbb3229 100644
--- a/libbb/lineedit.c
+++ b/libbb/lineedit.c
@@ -974,8 +974,10 @@ static NOINLINE unsigned complete_cmd_dir_file(const char *command, int type)
974 if (type == FIND_EXE_ONLY && !dirbuf) { 974 if (type == FIND_EXE_ONLY && !dirbuf) {
975# if ENABLE_FEATURE_SH_STANDALONE && NUM_APPLETS != 1 975# if ENABLE_FEATURE_SH_STANDALONE && NUM_APPLETS != 1
976 const char *p = applet_names; 976 const char *p = applet_names;
977# if ENABLE_PLATFORM_MINGW32
977 const char *shpath = state->flags & WITH_PATH_LOOKUP ? 978 const char *shpath = state->flags & WITH_PATH_LOOKUP ?
978 state->path_lookup : NULL; 979 state->path_lookup : NULL;
980# endif
979 while (*p) { 981 while (*p) {
980 if (strncmp(basecmd, p, baselen) == 0 && 982 if (strncmp(basecmd, p, baselen) == 0 &&
981 is_applet_preferred(p, shpath)) 983 is_applet_preferred(p, shpath))