diff options
author | Denis Vlasenko | 2007-05-17 13:02:41 +0000 |
---|---|---|
committer | Denis Vlasenko | 2007-05-17 13:02:41 +0000 |
commit | 96f67dc69d251168ea1c0adfaf6ff126d5dcbd36 (patch) | |
tree | c9a178cb85eaa3ae1e2386c7ae6e4c3f6c9f6924 | |
parent | d46e6d1a55f1182b8aa2d621a2532bad3bc20ee9 (diff) | |
download | busybox-96f67dc69d251168ea1c0adfaf6ff126d5dcbd36.zip busybox-96f67dc69d251168ea1c0adfaf6ff126d5dcbd36.tar.gz |
more compile fixes from randomconfig run
-rw-r--r-- | libbb/vfork_daemon_rexec.c | 2 | ||||
-rw-r--r-- | shell/hush.c | 16 |
2 files changed, 10 insertions, 8 deletions
diff --git a/libbb/vfork_daemon_rexec.c b/libbb/vfork_daemon_rexec.c index aef74e9..a2572b0 100644 --- a/libbb/vfork_daemon_rexec.c +++ b/libbb/vfork_daemon_rexec.c @@ -100,6 +100,7 @@ int wait_pid(int *wstat, int pid) return r; } +#if ENABLE_FEATURE_PREFER_APPLETS void save_nofork_data(struct nofork_save_area *save) { save->current_applet = current_applet; @@ -162,6 +163,7 @@ int run_nofork_applet(const struct bb_applet *a, char **argv) save_nofork_data(&old); return run_nofork_applet_prime(&old, a, argv); } +#endif /* FEATURE_PREFER_APPLETS */ int spawn_and_wait(char **argv) { diff --git a/shell/hush.c b/shell/hush.c index 7a4d7f9..0a035ca 100644 --- a/shell/hush.c +++ b/shell/hush.c @@ -486,6 +486,10 @@ static const struct built_in_command bltins[] = { { NULL, NULL, NULL } }; +#if ENABLE_FEATURE_SH_STANDALONE +struct nofork_save_area nofork_save; +#endif + #if ENABLE_HUSH_JOB /* move to libbb? */ @@ -537,10 +541,6 @@ static void set_every_sighandler(void (*handler)(int)) static struct pipe *toplevel_list; static sigjmp_buf toplevel_jb; smallint ctrl_z_flag; -#if ENABLE_FEATURE_SH_STANDALONE -struct nofork_save_area nofork_save; -#endif - static void handler_ctrl_c(int sig) { debug_printf_jobs("got sig %d\n", sig); @@ -1105,7 +1105,9 @@ static int file_get(struct in_str *i) /* If there is data waiting, eat it up */ if (i->p && *i->p) { +#if ENABLE_HUSH_INTERACTIVE take_cached: +#endif ch = *i->p++; if (i->eof_flag && !*i->p) ch = EOF; @@ -1120,11 +1122,9 @@ static int file_get(struct in_str *i) i->promptmode = 2; i->__promptme = 0; goto take_cached; - } else -#endif - { - ch = fgetc(i->file); } +#endif + ch = fgetc(i->file); } debug_printf("file_get: got a '%c' %d\n", ch, ch); #if ENABLE_HUSH_INTERACTIVE |