aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRon Yorston <rmy@pobox.com>2023-04-10 09:56:12 +0100
committerRon Yorston <rmy@pobox.com>2023-04-10 11:45:42 +0100
commit3165054d234e0f37f1a230312f1fd2ab3677bbc0 (patch)
treea5dd1939ede92ec5833c4cb446a36792b37a5051
parenta26711a2d1464167be4ebc990fe21a3809a2da34 (diff)
downloadbusybox-w32-3165054d234e0f37f1a230312f1fd2ab3677bbc0.tar.gz
busybox-w32-3165054d234e0f37f1a230312f1fd2ab3677bbc0.tar.bz2
busybox-w32-3165054d234e0f37f1a230312f1fd2ab3677bbc0.zip
ash,hush: rename get_builtin_name
Rename get_builtin_name() in ash and hush to avoid confusing bloatcheck. No functional changes. (GitHub issue #301) Signed-off-by: Ron Yorston <rmy@pobox.com>
-rw-r--r--shell/ash.c6
-rw-r--r--shell/hush.c4
2 files changed, 5 insertions, 5 deletions
diff --git a/shell/ash.c b/shell/ash.c
index d4ee4c93e..26239ff09 100644
--- a/shell/ash.c
+++ b/shell/ash.c
@@ -9732,7 +9732,7 @@ evalpipe(union node *n, int flags)
9732 9732
9733/* setinteractive needs this forward reference */ 9733/* setinteractive needs this forward reference */
9734#if ENABLE_FEATURE_TAB_COMPLETION 9734#if ENABLE_FEATURE_TAB_COMPLETION
9735static const char *get_builtin_name(int i) FAST_FUNC; 9735static const char *ash_builtin_name(int i) FAST_FUNC;
9736#endif 9736#endif
9737 9737
9738/* 9738/*
@@ -9769,7 +9769,7 @@ setinteractive(int on)
9769 if (!line_input_state) { 9769 if (!line_input_state) {
9770 line_input_state = new_line_input_t(FOR_SHELL | WITH_PATH_LOOKUP); 9770 line_input_state = new_line_input_t(FOR_SHELL | WITH_PATH_LOOKUP);
9771# if ENABLE_FEATURE_TAB_COMPLETION 9771# if ENABLE_FEATURE_TAB_COMPLETION
9772 line_input_state->get_exe_name = get_builtin_name; 9772 line_input_state->get_exe_name = ash_builtin_name;
9773# endif 9773# endif
9774# if EDITING_HAS_sh_get_var 9774# if EDITING_HAS_sh_get_var
9775 line_input_state->sh_get_var = lookupvar; 9775 line_input_state->sh_get_var = lookupvar;
@@ -10284,7 +10284,7 @@ find_builtin(const char *name)
10284 10284
10285#if ENABLE_FEATURE_TAB_COMPLETION 10285#if ENABLE_FEATURE_TAB_COMPLETION
10286static const char * FAST_FUNC 10286static const char * FAST_FUNC
10287get_builtin_name(int i) 10287ash_builtin_name(int i)
10288{ 10288{
10289 return /*i >= 0 &&*/ i < ARRAY_SIZE(builtintab) ? builtintab[i].name + 1 : NULL; 10289 return /*i >= 0 &&*/ i < ARRAY_SIZE(builtintab) ? builtintab[i].name + 1 : NULL;
10290} 10290}
diff --git a/shell/hush.c b/shell/hush.c
index a938cc790..330a0aa79 100644
--- a/shell/hush.c
+++ b/shell/hush.c
@@ -8220,7 +8220,7 @@ static const struct built_in_command *find_builtin(const char *name)
8220} 8220}
8221 8221
8222#if ENABLE_HUSH_JOB && ENABLE_FEATURE_TAB_COMPLETION 8222#if ENABLE_HUSH_JOB && ENABLE_FEATURE_TAB_COMPLETION
8223static const char * FAST_FUNC get_builtin_name(int i) 8223static const char * FAST_FUNC hush_builtin_name(int i)
8224{ 8224{
8225 if (/*i >= 0 && */ i < ARRAY_SIZE(bltins1)) { 8225 if (/*i >= 0 && */ i < ARRAY_SIZE(bltins1)) {
8226 return bltins1[i].b_cmd; 8226 return bltins1[i].b_cmd;
@@ -10716,7 +10716,7 @@ int hush_main(int argc, char **argv)
10716# if ENABLE_FEATURE_EDITING 10716# if ENABLE_FEATURE_EDITING
10717 G.line_input_state = new_line_input_t(FOR_SHELL); 10717 G.line_input_state = new_line_input_t(FOR_SHELL);
10718# if ENABLE_FEATURE_TAB_COMPLETION 10718# if ENABLE_FEATURE_TAB_COMPLETION
10719 G.line_input_state->get_exe_name = get_builtin_name; 10719 G.line_input_state->get_exe_name = hush_builtin_name;
10720# endif 10720# endif
10721# if EDITING_HAS_sh_get_var 10721# if EDITING_HAS_sh_get_var
10722 G.line_input_state->sh_get_var = get_local_var_value; 10722 G.line_input_state->sh_get_var = get_local_var_value;