summaryrefslogtreecommitdiffstats
path: root/common/parser.c
diff options
context:
space:
mode:
Diffstat (limited to 'common/parser.c')
-rw-r--r--common/parser.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/common/parser.c b/common/parser.c
index d390fb6afe..4a48210c4d 100644
--- a/common/parser.c
+++ b/common/parser.c
@@ -176,7 +176,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 run_command(const char *cmd)
{
char cmdbuf[CONFIG_CBSIZE]; /* working copy of cmd */
char *token; /* start of token in cmdbuf */
@@ -265,18 +265,17 @@ int run_shell(void)
static char lastcommand[CONFIG_CBSIZE] = { 0, };
int len;
int rc = 1;
- int flag;
+
for (;;) {
len = readline (CONFIG_PROMPT, console_buffer, CONFIG_CBSIZE);
- flag = 0; /* assume no special flags for now */
if (len > 0)
strcpy (lastcommand, console_buffer);
if (len == -1)
puts ("<INTERRUPT>\n");
else
- rc = run_command (lastcommand, flag);
+ rc = run_command(lastcommand);
if (rc <= 0) {
/* invalid command or not repeatable, forget it */