Bug 69768 - SEGV in killall
Summary: SEGV in killall
Status: Closed FIXED
Alias: None
Product: Base System
Classification: Unclassified
Component: misc (show other bugs)
Version: 4.10-STABLE
Hardware: Any Any
: Normal Affects Only Me
Assignee: Maxim Konovalov
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2004-07-29 18:20 UTC by bronek
Modified: 2004-08-05 05:07 UTC (History)
0 users

See Also:


Attachments
file.diff (959 bytes, patch)
2004-07-29 18:20 UTC, bronek
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description bronek 2004-07-29 18:20:29 UTC
killall is Segmention Fault if killing process is zombie

bronek# grep -nR NSIG /usr/src | more
..
/usr/src/usr.bin/killall/killall.c:203:                                 if (sig < 0 || sig > NSIG)
..
/usr/src/usr.sbin/ppp/sig.c:68:  if (sig <= 0 || sig > NSIG) {

..
the same bug propably in sig.c, but not vuln.

Fix: *** killall.c   xxx
How-To-Repeat: bronek# ps wuax | grep -w cu
uucp     419  0.0  0.3  1044  760  v0  IE+   1:09PM   0:00.02 cu -hl /dev/cuaa0
uucp     420  0.0  0.0     0    0  v0  Z+    1:09PM   0:00.00  (cu)
bronek# kill -9 419
bronek# kill -9 419
bronek# kill -9 420
420: No such process
bronek# kill -9 419
bronek# ps wuax | grep -w cu
uucp     419  0.0  0.3  1044  760  v0  IE+   1:09PM   0:00.02 cu -hl /dev/cuaa0
uucp     420  0.0  0.0     0    0  v0  Z+    1:09PM   0:00.00  (cu)
bronek# killall -9 cu
killall: kill -KILL 420: No such process
bronek# killall -32 cu
Segmentation fault (core dumped)
Comment 1 Maxim Konovalov freebsd_committer freebsd_triage 2004-07-29 19:42:07 UTC
State Changed
From-To: open->patched

Fixed in -CURRENT, thanks!
Comment 2 Maxim Konovalov freebsd_committer freebsd_triage 2004-07-29 19:42:35 UTC
Responsible Changed
From-To: freebsd-bugs->maxim

MFC reminder.
Comment 3 Maxim Konovalov freebsd_committer freebsd_triage 2004-08-05 05:07:06 UTC
State Changed
From-To: patched->closed

Fixed in -STABLE as well.