--- src/killall.c 2009-03-17 01:48:28 +0000 +++ src/killall.c 2009-03-17 02:00:55 +0000 @@ -19,6 +19,12 @@ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */ +/** + * Peter Lieverdink Tue Mar 17 13:00:15 EST 2009 + * + * Add the -H option to deal more efficiently with such frustrating + * things as pulseaudio and console-kit-daemon + */ #ifndef _GNU_SOURCE #define _GNU_SOURCE @@ -520,6 +526,7 @@ " -I,--ignore-case case insensitive process name match\n" " -g,--process-group kill process group instead of process\n" " -i,--interactive ask for confirmation before killing\n" + " -H,--with-a-hammer default to SIGKILL\n" " -l,--list list all known signal names\n" " -q,--quiet don't print complaints\n" " -r,--regexp interpret NAME as an extended regular expression\n" @@ -587,6 +594,7 @@ {"context", 1, NULL, 'Z'}, #endif /*WITH_SELINUX*/ {"version", 0, NULL, 'V'}, + {"with-a-hammer", 0, NULL, 'H'}, {0,0,0,0 }}; /* Setup the i18n */ @@ -613,9 +621,9 @@ opterr = 0; #ifdef WITH_SELINUX - while ( (optc = getopt_long_only(argc,argv,"egilqrs:u:vwZ:VI",options,NULL)) != EOF) { + while ( (optc = getopt_long_only(argc,argv,"egilqrs:u:vwZ:VIH",options,NULL)) != EOF) { #else - while ( (optc = getopt_long_only(argc,argv,"egilqrs:u:vwVI",options,NULL)) != EOF) { + while ( (optc = getopt_long_only(argc,argv,"egilqrs:u:vwVIH",options,NULL)) != EOF) { #endif switch (optc) { case 'e': @@ -667,6 +675,9 @@ usage(); wait_until_dead = 1; break; + case 'H': + sig_num = SIGKILL; + break; case 'I': ignore_case = 1; break;