Bug 85200

Summary: pstack fails for posix-threaded programs with only the main thread
Product: [Retired] Red Hat Linux Reporter: David Juran <djuran>
Component: pstackAssignee: Roland McGrath <roland>
Status: CLOSED ERRATA QA Contact:
Severity: medium Docs Contact:
Priority: medium    
Version: 8.0   
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2003-12-04 10:22:13 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Attachments:
Description Flags
testcase
none
and this remedies the problem none

Description David Juran 2003-02-26 16:45:29 UTC
From Bugzilla Helper:
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.2) Gecko/20021202

Description of problem:
pstack doesn't work for a program that only has one single thread, but is
compiled with the option -pthread.



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


How reproducible:
Always

Steps to Reproduce:
1.gcc -o test -pthread test.c
2. ./test
3.now attach to test with pstack and note that you don't get any output.
    

Actual Results:  32736: ./test

Expected Results:  32736: ./test
0x08048304: main + 0x10 (1, bffff0c4, bffff0cc, 400124b8, 1, 8048244)
0x420158d4: __libc_start_main + 0xa4 (80482f4, 1, bffff0c4, 804820c, 804832c,
4000a950) + 40000f48


Additional info:

Comment 1 David Juran 2003-02-26 16:46:15 UTC
Created attachment 90380 [details]
testcase

Comment 2 David Juran 2003-02-26 17:02:34 UTC
Created attachment 90382 [details]
and this remedies the problem

Comment 3 Roland McGrath 2003-11-12 01:40:16 UTC
I've implemented a different fix.  Thanks for the report.

Comment 4 David Juran 2003-12-04 10:22:13 UTC
Seems to work fine (-:

Comment 5 John Flanagan 2003-12-19 14:41:42 UTC
An errata has been issued which should help the problem described in this bug report. 
This report is therefore being closed with a resolution of ERRATA. For more information
on the solution and/or where to find the updated files, please follow the link below. You may reopen 
this bug report if the solution does not work for you.

http://rhn.redhat.com/errata/RHBA-2003-250.html