summaryrefslogtreecommitdiffstats
path: root/common/parser.c
diff options
context:
space:
mode:
authorSascha Hauer <s.hauer@pengutronix.de>2014-02-27 12:23:29 +0100
committerSascha Hauer <s.hauer@pengutronix.de>2014-03-07 07:41:26 +0100
commit93578fb2333bba3d1c2d0fa41de11ba4f92f9aed (patch)
tree0ded5f8c7eff310f441fe2cf1c939bbe3a86291b /common/parser.c
parent3ea30d9ce892a66d5161acd8afb24b755e3f2045 (diff)
downloadbarebox-93578fb2333bba3d1c2d0fa41de11ba4f92f9aed.tar.gz
run_command: remove unused flag parameter
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
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 d390fb6..4a48210 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 */