]> git.ipfire.org Git - thirdparty/systemd.git/commitdiff
core/killall: Add documentation about broadcast_signal() 12153/head
authorBenjamin Robin <dev@benjarobin.fr>
Mon, 8 Apr 2019 18:01:12 +0000 (20:01 +0200)
committerBenjamin Robin <dev@benjarobin.fr>
Wed, 10 Apr 2019 17:30:38 +0000 (19:30 +0200)
src/core/killall.c

index 056b36f07bba24144ebae05a045d17e74b8ad3ae..071091964072978af0bc180917a10edfcd73e357 100644 (file)
@@ -252,6 +252,12 @@ int broadcast_signal(int sig, bool wait_for_exit, bool send_sighup, usec_t timeo
         sigset_t mask, oldmask;
         _cleanup_set_free_ Set *pids = NULL;
 
+        /* Send the specified signal to all remaining processes, if not excluded by ignore_proc().
+         * Return:
+         *  - The number of processes still "alive" after the timeout (that should have been killed)
+         *    if the function needs to wait for the end of the processes (wait_for_exit).
+         *  - Otherwise, the number of processes to which the specified signal was sent */
+
         if (wait_for_exit)
                 pids = set_new(NULL);