[PATCH] busfault: Quash a valgrind complaint

Adam Jackson ajax at redhat.com
Tue Apr 8 06:05:17 PDT 2014


  Syscall param rt_sigaction(act->sa_mask) points to uninitialised byte(s)
     at 0x388520F85A: __libc_sigaction (sigaction.c:64)
     by 0x468161: busfault_init (busfault.c:145)
     by 0x46E09A: OsInit (osinit.c:191)
     by 0x43A3EA: dix_main (main.c:163)
     by 0x3884A21D64: (below main) (libc-start.c:285)
   Address 0xffeffedd8 is on thread 1's stack

I can't think of a reason to block any other signals while this is
running - both SIGALRM and SIGIO should be harmless here - so just set
the mask to empty.

Signed-off-by: Adam Jackson <ajax at redhat.com>
---
 os/busfault.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/os/busfault.c b/os/busfault.c
index 43bb6ea..bce7dfc 100644
--- a/os/busfault.c
+++ b/os/busfault.c
@@ -140,6 +140,7 @@ busfault_init(void)
 {
     struct sigaction    act, old_act;
 
+    sigemptyset(&act.sa_mask);
     act.sa_sigaction = busfault_sigaction;
     act.sa_flags = SA_SIGINFO;
     if (sigaction(SIGBUS, &act, &old_act) < 0)
-- 
1.9.0



More information about the xorg-devel mailing list