From: Riku Voipio <riku.voipio@iki.fi>
To: qemu-devel@nongnu.org
Subject: [Qemu-devel] [PATCH 2/3] flush stdout after printing usage()
Date: Sat, 28 Feb 2009 00:14:46 +0200 [thread overview]
Message-ID: <20090227221446.GA484@kos.to> (raw)
fixes qemu-arm|grep cpu - with _exit() getting output from qemu --help
is a bit random. Since no atexit() handlers are registered for user mode
emulation, just use exit() instead.
Signed-off-by: Riku Voipio <riku.voipio@iki.fi>
---
bsd-user/main.c | 4 ++--
darwin-user/main.c | 4 ++--
linux-user/main.c | 4 ++--
3 files changed, 6 insertions(+), 6 deletions(-)
diff --git a/bsd-user/main.c b/bsd-user/main.c
index 7d0d4b3..74a1ba6 100644
--- a/bsd-user/main.c
+++ b/bsd-user/main.c
@@ -351,7 +351,7 @@ static void usage(void)
interp_prefix,
x86_stack_size,
DEBUG_LOGFILE);
- _exit(1);
+ exit(1);
}
THREAD CPUState *thread_env;
@@ -448,7 +448,7 @@ int main(int argc, char **argv)
#if defined(cpu_list)
cpu_list(stdout, &fprintf);
#endif
- _exit(1);
+ exit(1);
}
} else if (!strcmp(r, "drop-ld-preload")) {
drop_ld_preload = 1;
diff --git a/darwin-user/main.c b/darwin-user/main.c
index 24e738b..9b8a3dc 100644
--- a/darwin-user/main.c
+++ b/darwin-user/main.c
@@ -756,7 +756,7 @@ void usage(void)
interp_prefix,
stack_size,
DEBUG_LOGFILE);
- _exit(1);
+ exit(1);
}
/* XXX: currently only used for async signals (see signal.c) */
@@ -840,7 +840,7 @@ int main(int argc, char **argv)
#if defined(cpu_list)
cpu_list(stdout, &fprintf);
#endif
- _exit(1);
+ exit(1);
}
} else
{
diff --git a/linux-user/main.c b/linux-user/main.c
index 00259dc..6e2984c 100644
--- a/linux-user/main.c
+++ b/linux-user/main.c
@@ -2213,7 +2213,7 @@ static void usage(void)
interp_prefix,
x86_stack_size,
DEBUG_LOGFILE);
- _exit(1);
+ exit(1);
}
THREAD CPUState *thread_env;
@@ -2335,7 +2335,7 @@ int main(int argc, char **argv, char **envp)
#if defined(cpu_list)
cpu_list(stdout, &fprintf);
#endif
- _exit(1);
+ exit(1);
}
} else if (!strcmp(r, "drop-ld-preload")) {
(void) envlist_unsetenv(envlist, "LD_PRELOAD");
--
1.6.1.3
--
"rm -rf" only sounds scary if you don't have backups
next reply other threads:[~2009-02-27 22:14 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-02-27 22:14 Riku Voipio [this message]
2009-02-28 20:14 ` [Qemu-devel] [PATCH 2/3] flush stdout after printing usage() Blue Swirl
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20090227221446.GA484@kos.to \
--to=riku.voipio@iki.fi \
--cc=qemu-devel@nongnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.