Author: eadler
Date: Sun Jun 10 06:21:45 2018
New Revision: 334916
URL: https://svnweb.freebsd.org/changeset/base/334916

Log:
  top(1): permit sending signal with any case

Modified:
  head/usr.bin/top/commands.c

Modified: head/usr.bin/top/commands.c
==============================================================================
--- head/usr.bin/top/commands.c Sun Jun 10 05:48:03 2018        (r334915)
+++ head/usr.bin/top/commands.c Sun Jun 10 06:21:45 2018        (r334916)
@@ -401,17 +401,17 @@ kill_procs(char *str)
            /* translate the name into a number */
            for (sigp = sigdesc; sigp->name != NULL; sigp++)
            {
-               if (strcmp(sigp->name, str + 1) == 0)
-               {
-                   signum = sigp->number;
-                   break;
+                       if (strcasecmp(sigp->name, str + 1) == 0)
+                       {
+                               signum = sigp->number;
+                               break;
+                       }
                }
-           }
 
            /* was it ever found */
            if (sigp->name == NULL)
            {
-               return(bad_signal_name);
+                       return(bad_signal_name);
            }
        }
        /* put the new pointer in place */
_______________________________________________
svn-src-all@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"

Reply via email to