* [Qemu-devel] [PATCH] linux-user/syscall.c: Don't skip stracing for fcntl64 failure case
@ 2011-12-05 23:11 Peter Maydell
2011-12-05 23:34 ` Alexander Graf
2011-12-06 10:45 ` [Qemu-devel] [Qemu-trivial] " Stefan Hajnoczi
0 siblings, 2 replies; 3+ messages in thread
From: Peter Maydell @ 2011-12-05 23:11 UTC (permalink / raw)
To: qemu-devel; +Cc: qemu-trivial, Riku Voipio, Alexander Graf, patches
In an fcntl64 failure path, we were returning directly rather than
simply breaking out of the switch statement. This skips the strace
code for printing the syscall return value, so don't do that.
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
---
Alex Graf spotted this one...
linux-user/syscall.c | 6 ++++--
1 files changed, 4 insertions(+), 2 deletions(-)
diff --git a/linux-user/syscall.c b/linux-user/syscall.c
index f227097..4846b41 100644
--- a/linux-user/syscall.c
+++ b/linux-user/syscall.c
@@ -7521,8 +7521,10 @@ abi_long do_syscall(void *cpu_env, int num, abi_long arg1,
#endif
cmd = target_to_host_fcntl_cmd(arg2);
- if (cmd == -TARGET_EINVAL)
- return cmd;
+ if (cmd == -TARGET_EINVAL) {
+ ret = cmd;
+ break;
+ }
switch(arg2) {
case TARGET_F_GETLK64:
--
1.7.5.4
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [Qemu-devel] [PATCH] linux-user/syscall.c: Don't skip stracing for fcntl64 failure case
2011-12-05 23:11 [Qemu-devel] [PATCH] linux-user/syscall.c: Don't skip stracing for fcntl64 failure case Peter Maydell
@ 2011-12-05 23:34 ` Alexander Graf
2011-12-06 10:45 ` [Qemu-devel] [Qemu-trivial] " Stefan Hajnoczi
1 sibling, 0 replies; 3+ messages in thread
From: Alexander Graf @ 2011-12-05 23:34 UTC (permalink / raw)
To: Peter Maydell; +Cc: qemu-trivial, Riku Voipio, qemu-devel, patches
On 06.12.2011, at 00:11, Peter Maydell wrote:
> In an fcntl64 failure path, we were returning directly rather than
> simply breaking out of the switch statement. This skips the strace
> code for printing the syscall return value, so don't do that.
>
> Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Acked-by: Alexander Graf <agraf@suse.de>
Alex
> ---
> Alex Graf spotted this one...
>
> linux-user/syscall.c | 6 ++++--
> 1 files changed, 4 insertions(+), 2 deletions(-)
>
> diff --git a/linux-user/syscall.c b/linux-user/syscall.c
> index f227097..4846b41 100644
> --- a/linux-user/syscall.c
> +++ b/linux-user/syscall.c
> @@ -7521,8 +7521,10 @@ abi_long do_syscall(void *cpu_env, int num, abi_long arg1,
> #endif
>
> cmd = target_to_host_fcntl_cmd(arg2);
> - if (cmd == -TARGET_EINVAL)
> - return cmd;
> + if (cmd == -TARGET_EINVAL) {
> + ret = cmd;
> + break;
> + }
>
> switch(arg2) {
> case TARGET_F_GETLK64:
> --
> 1.7.5.4
>
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [Qemu-devel] [Qemu-trivial] [PATCH] linux-user/syscall.c: Don't skip stracing for fcntl64 failure case
2011-12-05 23:11 [Qemu-devel] [PATCH] linux-user/syscall.c: Don't skip stracing for fcntl64 failure case Peter Maydell
2011-12-05 23:34 ` Alexander Graf
@ 2011-12-06 10:45 ` Stefan Hajnoczi
1 sibling, 0 replies; 3+ messages in thread
From: Stefan Hajnoczi @ 2011-12-06 10:45 UTC (permalink / raw)
To: Peter Maydell
Cc: qemu-trivial, Riku Voipio, qemu-devel, patches, Alexander Graf
On Mon, Dec 05, 2011 at 11:11:50PM +0000, Peter Maydell wrote:
> In an fcntl64 failure path, we were returning directly rather than
> simply breaking out of the switch statement. This skips the strace
> code for printing the syscall return value, so don't do that.
>
> Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
> ---
> Alex Graf spotted this one...
>
> linux-user/syscall.c | 6 ++++--
> 1 files changed, 4 insertions(+), 2 deletions(-)
Thanks, applied to the trivial patches tree:
http://repo.or.cz/w/qemu/stefanha.git/shortlog/refs/heads/trivial-patches
Stefan
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2011-12-06 10:45 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-12-05 23:11 [Qemu-devel] [PATCH] linux-user/syscall.c: Don't skip stracing for fcntl64 failure case Peter Maydell
2011-12-05 23:34 ` Alexander Graf
2011-12-06 10:45 ` [Qemu-devel] [Qemu-trivial] " Stefan Hajnoczi
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).