public inbox for glibc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug libc/748] New: SA_RESTART flag in sigaction is broken
@ 2005-02-16 14:58 sebastien dot decugis at ext dot bull dot net
  2005-02-16 15:00 ` [Bug libc/748] " sebastien dot decugis at ext dot bull dot net
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: sebastien dot decugis at ext dot bull dot net @ 2005-02-16 14:58 UTC (permalink / raw)
  To: glibc-bugs

When the SA_RESTART flag is set when installing a signal-catching function with
sigaction(), the signal should not cause an interruptible function to return
with error EINTR but instead the function should restart silently.

The attached test case shows that this behavior is broken on glibc 2.3.4 -- the
sem_wait function, when interrupted, returns with error EINTR.

-- 
           Summary: SA_RESTART flag in sigaction is broken
           Product: glibc
           Version: 2.3.4
            Status: NEW
          Severity: normal
          Priority: P2
         Component: libc
        AssignedTo: gotom at debian dot or dot jp
        ReportedBy: sebastien dot decugis at ext dot bull dot net
                CC: glibc-bugs at sources dot redhat dot com


http://sources.redhat.com/bugzilla/show_bug.cgi?id=748

------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.


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

* [Bug libc/748] SA_RESTART flag in sigaction is broken
  2005-02-16 14:58 [Bug libc/748] New: SA_RESTART flag in sigaction is broken sebastien dot decugis at ext dot bull dot net
@ 2005-02-16 15:00 ` sebastien dot decugis at ext dot bull dot net
  2005-02-16 15:19 ` jakub at redhat dot com
  2005-09-27  0:57 ` drepper at redhat dot com
  2 siblings, 0 replies; 4+ messages in thread
From: sebastien dot decugis at ext dot bull dot net @ 2005-02-16 15:00 UTC (permalink / raw)
  To: glibc-bugs


------- Additional Comments From sebastien dot decugis at ext dot bull dot net  2005-02-16 15:00 -------
Created an attachment (id=410)
 --> (http://sources.redhat.com/bugzilla/attachment.cgi?id=410&action=view)
test case for this bug.

compile with:
$ gcc -o bug_sigaction2 bug_sigaction2.c -lpthread

then just run:
$ ./bug_sigaction2


-- 


http://sources.redhat.com/bugzilla/show_bug.cgi?id=748

------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.


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

* [Bug libc/748] SA_RESTART flag in sigaction is broken
  2005-02-16 14:58 [Bug libc/748] New: SA_RESTART flag in sigaction is broken sebastien dot decugis at ext dot bull dot net
  2005-02-16 15:00 ` [Bug libc/748] " sebastien dot decugis at ext dot bull dot net
@ 2005-02-16 15:19 ` jakub at redhat dot com
  2005-09-27  0:57 ` drepper at redhat dot com
  2 siblings, 0 replies; 4+ messages in thread
From: jakub at redhat dot com @ 2005-02-16 15:19 UTC (permalink / raw)
  To: glibc-bugs


------- Additional Comments From jakub at redhat dot com  2005-02-16 15:19 -------
This sounds like kernel bug to me.
Guess returning -ERESTARTSYS; instead of -EINTR; in the only place in
kernel/futex.c that returns EINTR should fix it, but have not tested that.

-- 


http://sources.redhat.com/bugzilla/show_bug.cgi?id=748

------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.


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

* [Bug libc/748] SA_RESTART flag in sigaction is broken
  2005-02-16 14:58 [Bug libc/748] New: SA_RESTART flag in sigaction is broken sebastien dot decugis at ext dot bull dot net
  2005-02-16 15:00 ` [Bug libc/748] " sebastien dot decugis at ext dot bull dot net
  2005-02-16 15:19 ` jakub at redhat dot com
@ 2005-09-27  0:57 ` drepper at redhat dot com
  2 siblings, 0 replies; 4+ messages in thread
From: drepper at redhat dot com @ 2005-09-27  0:57 UTC (permalink / raw)
  To: glibc-bugs


------- Additional Comments From drepper at redhat dot com  2005-09-27 00:57 -------
Yes, this is a kernel issue and using ERESTARTSYS should fix it.

-- 
           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
         Resolution|                            |INVALID


http://sourceware.org/bugzilla/show_bug.cgi?id=748

------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.


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

end of thread, other threads:[~2005-09-27  0:57 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2005-02-16 14:58 [Bug libc/748] New: SA_RESTART flag in sigaction is broken sebastien dot decugis at ext dot bull dot net
2005-02-16 15:00 ` [Bug libc/748] " sebastien dot decugis at ext dot bull dot net
2005-02-16 15:19 ` jakub at redhat dot com
2005-09-27  0:57 ` drepper at redhat dot com

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).