aboutsummaryrefslogtreecommitdiff
path: root/lib/lib.c
diff options
context:
space:
mode:
Diffstat (limited to 'lib/lib.c')
-rw-r--r--lib/lib.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/lib.c b/lib/lib.c
index 76d5765c..54bfc8c4 100644
--- a/lib/lib.c
+++ b/lib/lib.c
@@ -907,7 +907,7 @@ int sig_to_num(char *pidstr)
if (!strncasecmp(pidstr, "sig", 3)) pidstr+=3;
}
- for (i = 0; i < sizeof(signames)/sizeof(struct signame); i++)
+ for (i=0; i<ARRAY_LEN(signames); i++)
if (!pidstr) xputs(signames[i].name);
else if (!strcasecmp(pidstr, signames[i].name)) return signames[i].num;
@@ -918,7 +918,7 @@ char *num_to_sig(int sig)
{
int i;
- for (i=0; i<sizeof(signames)/sizeof(struct signame); i++)
+ for (i=0; i<ARRAY_LEN(signames); i++)
if (signames[i].num == sig) return signames[i].name;
return NULL;
}