tile: compat rt_sigreturn gets too enthusiastic about sigaltstack errors
authorAl Viro <viro@zeniv.linux.org.uk>
Thu, 29 Nov 2012 02:43:21 +0000 (21:43 -0500)
committerAl Viro <viro@zeniv.linux.org.uk>
Thu, 29 Nov 2012 02:43:21 +0000 (21:43 -0500)
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
arch/tile/kernel/compat_signal.c

index 210a9bbae96322b8b530b8e3aa2bafafeabbc021..2e4cc69224a6ff83ed5bc0dbe8e4544891b8d99f 100644 (file)
@@ -248,7 +248,7 @@ long compat_sys_rt_sigreturn(void)
        if (restore_sigcontext(regs, &frame->uc.uc_mcontext))
                goto badframe;
 
-       if (compat_sys_sigaltstack(&frame->uc.uc_stack, NULL) != 0)
+       if (compat_sys_sigaltstack(&frame->uc.uc_stack, NULL) == -EFAULT)
                goto badframe;
 
        return 0;