Bug 65790 - exit () system call not thread safe
exit () system call not thread safe
Product: Red Hat Linux
Classification: Retired
Component: libc (Show other bugs)
i686 Linux
medium Severity high
: ---
: ---
Assigned To: Jakub Jelinek
Depends On:
  Show dependency treegraph
Reported: 2002-05-31 14:22 EDT by Suresh Rao
Modified: 2008-05-01 11:38 EDT (History)
1 user (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2002-12-15 15:44:46 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)
test file (6.00 KB, text/plain)
2002-05-31 14:25 EDT, Suresh Rao
no flags Details

  None (edit)
Description Suresh Rao 2002-05-31 14:22:00 EDT
From Bugzilla Helper:
User-Agent: Mozilla/4.0 (compatible; MSIE 5.0; Windows NT; DigExt)

Description of problem:
exit() system call is not thread safe. When can we expect a fix for this.

Version-Release number of selected component (if applicable):

How reproducible:

Steps to Reproduce:
1.compile/link attached test program with gcc for ia32 
2.execution shows error.

Actual Results:  "ERROR: creating thread" from test program

Expected Results:  Exit with no error message

Additional info:
Comment 1 Suresh Rao 2002-05-31 14:25:54 EDT
Created attachment 59124 [details]
test file
Comment 2 Jakub Jelinek 2002-05-31 15:34:31 EDT
Verified. Will work on this after the weekend.
Comment 3 Jakub Jelinek 2002-06-04 07:26:05 EDT
http://www.opengroup.org/onlinepubs/007908799/xsh/_exit.html says:
If exit() is called more than once, the effects are undefined.
So I'm not exactly sure if we want to do anything about it.
I'll discuss this with other glibc authors.
Comment 4 Jason Merrill 2002-11-07 23:09:14 EST
It seems to me that the affected code should be calling pthread_exit rather than
exit, and that the failure helps to alert users to the error in their code.

Note You need to log in before you can comment on or make changes to this bug.