From 99de7009698d868c0d139133ed4fa445be8cae50 Mon Sep 17 00:00:00 2001 From: Ron Yorston Date: Tue, 23 Jan 2024 09:24:38 +0000 Subject: 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. --- libbb/lineedit.c | 2 ++ 1 file changed, 2 insertions(+) (limited to 'libbb/lineedit.c') 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) if (type == FIND_EXE_ONLY && !dirbuf) { # if ENABLE_FEATURE_SH_STANDALONE && NUM_APPLETS != 1 const char *p = applet_names; +# if ENABLE_PLATFORM_MINGW32 const char *shpath = state->flags & WITH_PATH_LOOKUP ? state->path_lookup : NULL; +# endif while (*p) { if (strncmp(basecmd, p, baselen) == 0 && is_applet_preferred(p, shpath)) -- cgit v1.2.3-55-g6feb