From f47360a74ec05c078960bf6f8c10a7f426c7d11d Mon Sep 17 00:00:00 2001 From: Simon Glass Date: Tue, 14 Feb 2012 19:59:19 +0000 Subject: Rename run_command() to builtin_run_command() The current run_command() is only one of the parsing options - the other is hush. We should not call run_command() when the hush parser is being used. So we rename this function to better explain its purpose. Signed-off-by: Simon Glass Acked-by: Mike Frysinger --- common/main.c | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) (limited to 'common/main.c') diff --git a/common/main.c b/common/main.c index defe2d499d8..e74ebdfbf66 100644 --- a/common/main.c +++ b/common/main.c @@ -274,9 +274,10 @@ int run_command2(const char *cmd, int flag) { #ifndef CONFIG_SYS_HUSH_PARSER /* - * run_command can return 0 or 1 for success, so clean up its result. + * builtin_run_command can return 0 or 1 for success, so clean up + * its result. */ - if (run_command(cmd, flag) == -1) + if (builtin_run_command(cmd, flag) == -1) return 1; return 0; @@ -457,7 +458,7 @@ void main_loop (void) if (len == -1) puts ("\n"); else - rc = run_command (lastcommand, flag); + rc = builtin_run_command(lastcommand, flag); if (rc <= 0) { /* invalid command or not repeatable, forget it */ @@ -1278,7 +1279,7 @@ static void process_macros (const char *input, char *output) * creates or modifies environment variables (like "bootp" does). */ -int run_command (const char *cmd, int flag) +int builtin_run_command(const char *cmd, int flag) { cmd_tbl_t *cmdtp; char cmdbuf[CONFIG_SYS_CBSIZE]; /* working copy of cmd */ -- cgit v1.2.3