]> git.ipfire.org Git - thirdparty/util-linux.git/commitdiff
kill: deprecat invocation as 'pid' command name
authorSami Kerola <kerolasa@iki.fi>
Sun, 9 Mar 2014 17:45:35 +0000 (12:45 -0500)
committerSami Kerola <kerolasa@iki.fi>
Sun, 30 Mar 2014 20:32:36 +0000 (21:32 +0100)
Enabling options by renaming command is both unexpected and undocumented.
This magic is now deprecated and with remark of removal of this
functionality in future.

Signed-off-by: Sami Kerola <kerolasa@iki.fi>
misc-utils/kill.1
misc-utils/kill.c

index 50f5cd206190d19c43ecabc0159b67e726868938..610f8fb72cbc40260da455c44c867f512010ff2b 100644 (file)
@@ -88,6 +88,11 @@ Specify that
 .B kill
 should only print the process id (pid) of the named processes, and not send any
 signals.
+.IP
+The \-\-pid option functionality is enabled when the command
+copied or linked to name
+.BR pid .
+This functionality is deprecated, and will not be removed in March 2016.
 .TP
 \fB\-q\fR, \fB\-\-queue\fR \fIsigval\fR
 Use
index 2fecda39e07043fcb69656baab4b6b493f49843e..c9c1bda1a2e3545815daf2c4bc73de7efe4918aa 100644 (file)
@@ -170,6 +170,8 @@ int main(int argc, char **argv)
 
        numsig = SIGTERM;
        do_pid = (!strcmp(program_invocation_short_name, "pid"));       /* Yecch */
+       if (do_pid)     /* FIXME: remove in March 2016.  */
+               warnx(_("use of 'kill --pid' option as command name is deprecated"));
        do_kill = 0;
        check_all = 0;
        /* Loop through the arguments.  Actually, -a is the only option