Bug 83417

Summary: emacs reports incorrect process exit status
Product: [Retired] Red Hat Raw Hide Reporter: Jonathan Kamens <jik>
Component: kernelAssignee: Arjan van de Ven <arjanv>
Status: CLOSED RAWHIDE QA Contact: Brian Brock <bbrock>
Severity: high Docs Contact:
Priority: medium    
Version: 1.0CC: petersen
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-02-20 03:45:27 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:
Bug Depends On:    
Bug Blocks: 79578    

Description Jonathan Kamens 2003-02-04 03:10:20 UTC
I updated to the current Raw Hide earlier today.  That means glibc-2.3.1-40 and
emacs-21.2-30, among other things.

Emacs is now claiming that a process exited with status 1 when in fact it exited
with status 5.  Try this....

1) Create a file "/tmp/exit5.sh" with these contents:

  #!/bin/sh
  sleep 5
  exit 5

2) Make it executable.

3) Define and run this function:

  (defun test-exit-status ()
    (interactive)
    (let (process)
      (make-comint "foo" "/tmp/exit5.sh")
      (setq process (get-buffer-process (get-buffer "*foo*")))
      (sleep-for 6)
      (message (format "Exit status is %d" (process-exit-status process)))))

It will display the message "Exit status is 1", when it should display "Exit
status is 5".  This is a pretty serious change in functionality, and it breaks
stuff that I do in Emacs every single day.

Comment 1 Jens Petersen 2003-02-05 05:42:32 UTC
Reproduced with kernel-2.4.20-2.33.  I heard that this is known
current kernel bug that "makes many things wrongly show death by SIGHUP
when they exit".  [Doesn't happen with 2.4.20-2.21 for sure, nor -2.27 iirc.]

Comment 2 Bill Nottingham 2003-02-18 01:01:15 UTC
Does this still happen with 2.49?

Comment 3 Jonathan Kamens 2003-02-20 03:45:27 UTC
It seems OK in 2.49.