Bug 97047 - Calls to getppid() are cached
Calls to getppid() are cached
Product: Red Hat Linux
Classification: Retired
Component: perl (Show other bugs)
i386 Linux
high Severity medium
: ---
: ---
Assigned To: Jason Vas Dias
David Lawrence
Depends On:
  Show dependency treegraph
Reported: 2003-06-09 12:56 EDT by Magnus Erixzon
Modified: 2007-03-27 00:06 EDT (History)
1 user (show)

See Also:
Fixed In Version: ALL
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2005-11-11 19:56:57 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

  None (edit)
Description Magnus Erixzon 2003-06-09 12:56:39 EDT
Description of problem:

Calls to getppid() are cached. If the parent pid changes, new calls to getppid() does not show this.

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


How reproducible:

Steps to Reproduce:
1. fork, then let parent wait()
2. let child fork
3. child #2 calls getppid(). Returns pid of child #1, as expected.
4. child #2 exits. This will also exit the parent and set parent pid of child #2 to 1
5. child #2 calls getppid(). It still returns the same parent pid.
Actual results:

Old parent pid is returned from getppid() even when the parent pid has changed.

Expected results:

When the parent pid has changed, so should the return value from getppid()

Additional info:
Comment 1 Magnus Erixzon 2003-06-09 16:19:27 EDT
A typo..
Step 4 in Steps to Reproduce should of course be "child #1".
Comment 2 Jason Vas Dias 2005-11-11 19:56:57 EST
Very sorry for the long delay in processing this bug .
This problem is fixed in all current Red Hat perl releases .

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