This is the mail archive of the
glibc-bugs@sourceware.org
mailing list for the glibc project.
[Bug libc/4067] possible problem in sigaction resulting into segfault
- From: "nico-linux-glibc at schottelius dot org" <sourceware-bugzilla at sourceware dot org>
- To: glibc-bugs at sources dot redhat dot com
- Date: 17 Feb 2007 16:38:11 -0000
- Subject: [Bug libc/4067] possible problem in sigaction resulting into segfault
- References: <20070216223621.4067.nico-linux-glibc@schottelius.org>
- Reply-to: sourceware-bugzilla at sourceware dot org
------- Additional Comments From nico-linux-glibc at schottelius dot org 2007-02-17 16:38 -------
same happens on glibc-2.4-7mdv2007.0:
[...]
testC
=> cinit started.
test2 - es scheint zu gehen
[SERVICE] /etc/cinit/svc/init: [ FAILED] Service failed!
Finished CHILD catcher
Segmentation fault
If I init the sa.flags it does not segfault:
[telmich@jonas src]$ diff -u core/set_signals.c.segfault core/set_signals.c
--- core/set_signals.c.segfault 2007-02-17 16:34:39.000000000 +0100
+++ core/set_signals.c 2007-02-17 16:34:46.000000000 +0100
@@ -18,17 +18,17 @@
if(action == ACT_SERV) {
sa.sa_handler = sig_child;
-// sa.sa_flags = SA_NOCLDSTOP;
+ sa.sa_flags = SA_NOCLDSTOP;
} else {
sa.sa_handler=SIG_DFL;
-// sa.sa_flags = 0;
+ sa.sa_flags = 0;
}
-// sigemptyset(&sa.sa_mask);
+ sigemptyset(&sa.sa_mask);
sigaction(SIGCHLD,&sa,NULL); /* what todo when a child exited */
/* reset flags */
-// sa.sa_flags = 0;
+ sa.sa_flags = 0;
if(action == ACT_SERV) {
sa.sa_handler=do_reboot;
}
The version:
[telmich@jonas src]$ /lib/libc.so.6
GNU C Library development release version 2.4, by Roland McGrath et al.
Copyright (C) 2006 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.
There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A
PARTICULAR PURPOSE.
Compiled by GNU CC version 4.1.1 20060724 (prerelease) (4.1.1-3mdk).
Compiled on a Linux 2.6.17 system on 2007-01-18.
Available extensions:
crypt add-on version 2.1 by Michael Glad and others
GNU libio by Per Bothner
NIS(YP)/NIS+ NSS modules 0.19 by Thorsten Kukuk
Native POSIX Threads Library by Ulrich Drepper et al
BIND-8.2.3-T5B
Thread-local storage support included.
For bug reporting instructions, please see:
<http://www.gnu.org/software/libc/bugs.html>.
--
What |Removed |Added
----------------------------------------------------------------------------
Status|RESOLVED |REOPENED
Resolution|WORKSFORME |
Version|2.3.6 |2.4
http://sourceware.org/bugzilla/show_bug.cgi?id=4067
------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.