From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([140.186.70.92]:48256) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RvnDC-0003mh-Fn for qemu-devel@nongnu.org; Fri, 10 Feb 2012 04:56:19 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1RvnD5-00022S-DO for qemu-devel@nongnu.org; Fri, 10 Feb 2012 04:56:14 -0500 MIME-Version: 1.0 Sender: alex.barcelo@gmail.com From: Alex Barcelo Date: Fri, 10 Feb 2012 10:55:46 +0100 Message-ID: Content-Type: text/plain; charset=ISO-8859-1 Subject: [Qemu-devel] [TRIVIAL v2] Bad zero comparison for sas_ss_flags on powerpc List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel Cc: qemu-trivial@nongnu.org, Riku Voipio This is v2 of the patch "sas_ss_flags bug for powerpc", which had a horrible name and no description. All architectures work the same way, and all check for sas_ss_flags == 0. The powerpc lines are wrong, and do the check the other way round (it's a qemu internal check, which is done wrong only for this architecture, it's more a typo than a bug). It's NOT ppc specific, it's POSIX standard (sigaltstack) and qemu internal. I have a test source that I will send in a follow-up (it's longer than I would have wished, I'm sure that a better test case can be written if needed) Signed-off-by: Alex Barcelo --- linux-user/signal.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/linux-user/signal.c b/linux-user/signal.c index 79a39dc..26e0530 100644 --- a/linux-user/signal.c +++ b/linux-user/signal.c @@ -4115,7 +4115,7 @@ static target_ulong get_sigframe(struct target_sigaction *ka, oldsp = env->gpr[1]; if ((ka->sa_flags & TARGET_SA_ONSTACK) && - (sas_ss_flags(oldsp))) { + (sas_ss_flags(oldsp)) == 0) { oldsp = (target_sigaltstack_used.ss_sp + target_sigaltstack_used.ss_size); } -- 1.7.5.4