SHA256
1
0
forked from pool/strace
strace/0007-m68k-fix-sigreturn-decoding.patch
Martin Pluskal 0b44e76647 Accepting request 292570 from home:Andreas_Schwab:Factory
- 0001-aarch64-fix-rt_sigreturn-decoding.patch,
  0002-m68k-define-HAVE_SA_RESTORER.patch,
  0003-Fix-decoding-of-mmap2-for-arm.patch,
  0005-tests-select.test-handle-architectures-using-pselect.patch,
  0006-aarch64-fix-ioctl-decoding.patch,
  0007-m68k-fix-sigreturn-decoding.patch,
  0008-Fix-crash-in-ipc_sem-test.patch,
  0009-tests-ipc_-match-IPC_64-flag.patch,
  0010-semctl-fix-indirect-syscall-decoding.patch,
  0011-Fix-stat64-st_-acm-time-decoding-for-personalities-w.patch,
  0012-tests-verify-that-all-patterns-match.patch,
  0013-aarch64-properly-decode-generic-syscalls.patch,
  0014-stat64-v.test-add-newfstatat-syscall-support.patch,
  0015-tests-uid-use-fchown-instead-of-chown.patch: Patches from upstream
  to fix testsuite failure.
- Enable libunwind support (strace -k).

OBS-URL: https://build.opensuse.org/request/show/292570
OBS-URL: https://build.opensuse.org/package/show/devel:tools/strace?expand=0&rev=44
2015-03-24 18:25:03 +00:00

41 lines
1.2 KiB
Diff

From 712f0e12bd3cc2059229cbe301192768ab7fea07 Mon Sep 17 00:00:00 2001
From: Andreas Schwab <schwab@suse.de>
Date: Wed, 11 Mar 2015 15:08:42 +0100
Subject: [PATCH 07/15] m68k: fix sigreturn decoding
* sigreturn.c (sys_sigreturn) [M68K]: Fetch the words of the
signal mask from the proper place.
---
sigreturn.c | 14 +++++++++++++-
1 file changed, 13 insertions(+), 1 deletion(-)
diff --git a/sigreturn.c b/sigreturn.c
index c253a0c..365ef1a 100644
--- a/sigreturn.c
+++ b/sigreturn.c
@@ -128,8 +128,20 @@ sys_sigreturn(struct tcb *tcp)
long addr;
if (upeek(tcp->pid, 4*PT_USP, &addr) < 0)
return 0;
+ /* Fetch pointer to struct sigcontext. */
+ if (umove(tcp, addr + 2 * sizeof(int), &addr) < 0)
+ return 0;
+ unsigned long mask[NSIG / 8 / sizeof(long)];
+ /* Fetch first word of signal mask. */
+ if (umove(tcp, addr, &mask[0]) < 0)
+ return 0;
+ /* Fetch remaining words of signal mask, located
+ immediately before. */
+ addr -= sizeof(mask) - sizeof(long);
+ if (umoven(tcp, addr, sizeof(mask) - sizeof(long), (char *) &mask[1]) < 0)
+ return 0;
tprints("{mask=");
- print_sigset_addr_len(tcp, addr, NSIG / 8);
+ tprintsigmask_addr("", mask);
tprints("}");
}
#elif defined(ALPHA)
--
2.3.3