[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#668416: killproc incorrect exit status



Package: lsb-base
Version: 4.1+Debian0
Severity: normal

Somewhere between versions 3.2+Debian31 and 4.1+Debian0, the exit
status of the killproc function (/lib/lsb/init-functions) was changed
to return 3 when the program is not running.  This is only correct
when a signal was specified; see
<http://refspecs.linuxbase.org/LSB_4.1.0/LSB-Core-generic/LSB-Core-generic/iniscrptfunc.html>:

    If called without a signal, it shall return 0 if the program has
    been stopped or is not running and not 0 otherwise. If a signal is
    given, it shall return 0 only if the program is running.

This breaks init scripts that rely on this behavior; see for example
bug #667623.

Simple test:

    sudo bash
    . /lib/lsb/init-functions
    killproc /usr/bin/nonexistent
    echo $?

should print 0.  It now prints 3.



Reply to: