All of lore.kernel.org
 help / color / mirror / Atom feed
* [LTP] Rt_sigprocmask01 test case caused "segment fault" on x86
@ 2010-08-18 11:22 Fu, Yingang
  2010-08-24 11:02 ` Subrata Modak
  0 siblings, 1 reply; 5+ messages in thread
From: Fu, Yingang @ 2010-08-18 11:22 UTC (permalink / raw)
  To: yanegomi; +Cc: ltp-list


[-- Attachment #1.1: Type: text/plain, Size: 425 bytes --]

hi, Garrett
 
This is a similar problem as rt_sigsuspend01 which has been fix before.
 
Failed log:

root@Congatec:/opt/ltp-full> ./testcases/bin/rt_sigprocmask01
Segmentation fault

After apply the patch:
root@Congatec:/opt/ltp-full> ./testcases/bin/rt_sigprocmask01
rt_sigprocmask01    1  TPASS  :  rt_sigprocmask functionality passed

Signed-off-by: Yingang Fu <yingang.fu@windriver.com>
 
Thanks
Yingang

[-- Attachment #1.2: Type: text/html, Size: 1294 bytes --]

[-- Attachment #2: 0001-sigaction-variables-must-be-initialized-before-using.patch --]
[-- Type: application/octet-stream, Size: 956 bytes --]

From eca5c85e59bf92cbd49272c3dc0ab25d63bc1e8d Mon Sep 17 00:00:00 2001
From: Yingang Fu <yingang.fu@windriver.com>
Date: Wed, 18 Aug 2010 19:06:56 +0800
Subject: [PATCH] sigaction variables must be initialized before using them. Otherwise,will
 cause "segment fault" on x86 platform

---
 .../syscalls/rt_sigprocmask/rt_sigprocmask01.c     |    2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)

diff --git a/testcases/kernel/syscalls/rt_sigprocmask/rt_sigprocmask01.c b/testcases/kernel/syscalls/rt_sigprocmask/rt_sigprocmask01.c
index e100561..33202f1 100644
--- a/testcases/kernel/syscalls/rt_sigprocmask/rt_sigprocmask01.c
+++ b/testcases/kernel/syscalls/rt_sigprocmask/rt_sigprocmask01.c
@@ -142,6 +142,8 @@ int main(int ac, char **av) {
 	act.k_sa_handler = sig_handler;
 #else
 	struct sigaction act, oact;
+	memset(&act,0,sizeof(act));
+	memset(&oact,0,sizeof(oact));
 	act.sa_handler = sig_handler;
 #endif
 	sigset_t set, oset;
-- 
1.7.0.5


[-- Attachment #3: Type: text/plain, Size: 224 bytes --]

------------------------------------------------------------------------------
This SF.net email is sponsored by 

Make an app they can't live without
Enter the BlackBerry Developer Challenge
http://p.sf.net/sfu/RIM-dev2dev 

[-- Attachment #4: Type: text/plain, Size: 155 bytes --]

_______________________________________________
Ltp-list mailing list
Ltp-list@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/ltp-list

^ permalink raw reply related	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2010-08-30 19:44 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-08-18 11:22 [LTP] Rt_sigprocmask01 test case caused "segment fault" on x86 Fu, Yingang
2010-08-24 11:02 ` Subrata Modak
2010-08-28  2:25   ` Henry Yei
2010-08-28  8:30     ` Garrett Cooper
2010-08-30 19:43       ` Henry Yei

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.