diff options
Diffstat (limited to 'shell')
-rw-r--r-- | shell/ash.c | 7 | ||||
-rw-r--r-- | shell/hush.c | 5 |
2 files changed, 5 insertions, 7 deletions
diff --git a/shell/ash.c b/shell/ash.c index ef4a47afe..d29de37b7 100644 --- a/shell/ash.c +++ b/shell/ash.c | |||
@@ -9720,7 +9720,7 @@ evalpipe(union node *n, int flags) | |||
9720 | } | 9720 | } |
9721 | 9721 | ||
9722 | /* setinteractive needs this forward reference */ | 9722 | /* setinteractive needs this forward reference */ |
9723 | #if EDITING_HAS_get_exe_name | 9723 | #if ENABLE_FEATURE_EDITING |
9724 | static const char *get_builtin_name(int i) FAST_FUNC; | 9724 | static const char *get_builtin_name(int i) FAST_FUNC; |
9725 | #endif | 9725 | #endif |
9726 | 9726 | ||
@@ -9757,9 +9757,8 @@ setinteractive(int on) | |||
9757 | #if ENABLE_FEATURE_EDITING | 9757 | #if ENABLE_FEATURE_EDITING |
9758 | if (!line_input_state) { | 9758 | if (!line_input_state) { |
9759 | line_input_state = new_line_input_t(FOR_SHELL | WITH_PATH_LOOKUP); | 9759 | line_input_state = new_line_input_t(FOR_SHELL | WITH_PATH_LOOKUP); |
9760 | # if EDITING_HAS_get_exe_name | ||
9761 | line_input_state->get_exe_name = get_builtin_name; | 9760 | line_input_state->get_exe_name = get_builtin_name; |
9762 | # endif | 9761 | line_input_state->sh_get_var = lookupvar; |
9763 | } | 9762 | } |
9764 | #endif | 9763 | #endif |
9765 | } | 9764 | } |
@@ -10262,7 +10261,7 @@ find_builtin(const char *name) | |||
10262 | return bp; | 10261 | return bp; |
10263 | } | 10262 | } |
10264 | 10263 | ||
10265 | #if EDITING_HAS_get_exe_name | 10264 | #if ENABLE_FEATURE_EDITING |
10266 | static const char * FAST_FUNC | 10265 | static const char * FAST_FUNC |
10267 | get_builtin_name(int i) | 10266 | get_builtin_name(int i) |
10268 | { | 10267 | { |
diff --git a/shell/hush.c b/shell/hush.c index ae81f0da5..051b123e7 100644 --- a/shell/hush.c +++ b/shell/hush.c | |||
@@ -8188,7 +8188,7 @@ static const struct built_in_command *find_builtin(const char *name) | |||
8188 | return find_builtin_helper(name, bltins2, &bltins2[ARRAY_SIZE(bltins2)]); | 8188 | return find_builtin_helper(name, bltins2, &bltins2[ARRAY_SIZE(bltins2)]); |
8189 | } | 8189 | } |
8190 | 8190 | ||
8191 | #if ENABLE_HUSH_JOB && EDITING_HAS_get_exe_name | 8191 | #if ENABLE_HUSH_JOB && ENABLE_FEATURE_EDITING |
8192 | static const char * FAST_FUNC get_builtin_name(int i) | 8192 | static const char * FAST_FUNC get_builtin_name(int i) |
8193 | { | 8193 | { |
8194 | if (/*i >= 0 && */ i < ARRAY_SIZE(bltins1)) { | 8194 | if (/*i >= 0 && */ i < ARRAY_SIZE(bltins1)) { |
@@ -10668,9 +10668,8 @@ int hush_main(int argc, char **argv) | |||
10668 | 10668 | ||
10669 | # if ENABLE_FEATURE_EDITING | 10669 | # if ENABLE_FEATURE_EDITING |
10670 | G.line_input_state = new_line_input_t(FOR_SHELL); | 10670 | G.line_input_state = new_line_input_t(FOR_SHELL); |
10671 | # if EDITING_HAS_get_exe_name | ||
10672 | G.line_input_state->get_exe_name = get_builtin_name; | 10671 | G.line_input_state->get_exe_name = get_builtin_name; |
10673 | # endif | 10672 | G.line_input_state->sh_get_var = get_local_var_value; |
10674 | # endif | 10673 | # endif |
10675 | # if ENABLE_HUSH_SAVEHISTORY && MAX_HISTORY > 0 | 10674 | # if ENABLE_HUSH_SAVEHISTORY && MAX_HISTORY > 0 |
10676 | { | 10675 | { |