diff options
author | Sascha Hauer <s.hauer@pengutronix.de> | 2012-05-23 16:11:39 +0200 |
---|---|---|
committer | Sascha Hauer <s.hauer@pengutronix.de> | 2012-05-23 16:11:39 +0200 |
commit | 10ea54dc508f170d251b31c7c2e163298a414653 (patch) | |
tree | d42723af18a02453e6724f6413c6af4ec4db8476 | |
parent | 06d7847cf0063cceec9a60eb526f03fcc7729769 (diff) | |
parent | 9448aa57ec58ac6f51fe970595517972e36cf44d (diff) | |
download | barebox-10ea54dc508f170d251b31c7c2e163298a414653.tar.gz barebox-10ea54dc508f170d251b31c7c2e163298a414653.tar.xz |
Merge branch 'pu/hush' into next
-rw-r--r-- | common/hush.c | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/common/hush.c b/common/hush.c index 3d51e4cc1..8e8dd03eb 100644 --- a/common/hush.c +++ b/common/hush.c @@ -1612,7 +1612,6 @@ static int parse_stream_outer(struct p_context *ctx, struct in_str *inp, int fla } if (inp->__promptme == 0) printf("<INTERRUPT>\n"); - inp->__promptme = 1; temp.nonnull = 0; temp.quote = 0; free_pipe_list(ctx->list_head,0); @@ -1807,9 +1806,12 @@ int run_shell(void) struct in_str input; struct p_context ctx; - setup_file_in_str(&input); - rcode = parse_stream_outer(&ctx, &input, FLAG_PARSE_SEMICOLON); - release_context(&ctx); + do { + setup_file_in_str(&input); + rcode = parse_stream_outer(&ctx, &input, FLAG_PARSE_SEMICOLON); + release_context(&ctx); + } while (!input.__promptme); + return rcode; } |