Bug 98263 - killall send wrong signals due to bad option parsing
killall send wrong signals due to bad option parsing
Status: CLOSED RAWHIDE
Product: Red Hat Linux
Classification: Retired
Component: psmisc (Show other bugs)
9
All Linux
medium Severity medium
: ---
: ---
Assigned To: Mike A. Harris
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2003-06-29 11:18 EDT by David Nečas
Modified: 2007-04-18 12:55 EDT (History)
0 users

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2003-09-27 13:43:52 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)
proposed patch (706 bytes, patch)
2003-06-29 11:20 EDT, David Nečas
no flags Details | Diff

  None (edit)
Description David Nečas 2003-06-29 11:18:57 EDT
From Bugzilla Helper:
User-Agent: Mozilla/5.0 Galeon/1.2.10 (X11; Linux i686; U;) Gecko/20030314

Description of problem:
The -S option makes impossible to pass -SEGV, -STOP, -STKFLT, and -SYS as
signals on the command line. The -S option exists only with FLASK_LINUX defined
(which is not the case of RedHat Linux), but the list of short options given to
getopt_long() includes is always.

The net result is that trying to send any of these signals makes killall to send
a SIGTERM instead of the specified signal.


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

How reproducible:
Always

Steps to Reproduce:
1. Create do_nothing.c:

int main(void) { while (1) ; }

compile it:

make do_nothing

2. Run it in the background in bash

./do_nothing &

3. Run

killall -STOP do_nothing

4. Press Enter


Actual Results:
[1]+  Terminated              ./do_nothing


Expected Results:
[1]+  Stopped                 ./do_nothing


Additional info:

A patch is proposed. It fixes it w/o FLASK_LINUX -- with FLASK_LINUX it can be
reasonably fixed only by renaming the -S option to something sane.
Comment 1 David Nečas 2003-06-29 11:20:33 EDT
Created attachment 92678 [details]
proposed patch
Comment 3 David Nečas 2003-09-27 13:43:52 EDT
The bug was fixed in upstream psmisc-21.3, included in RawHide/Severn. Thus I'm
closing it. Thanks for cooperation...

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