top(1): permit sending signal with any case

This commit is contained in:
eadler 2018-06-10 06:21:45 +00:00
parent 873da15eec
commit 18f78f76b1

View File

@ -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 */