Use nitems() from sys/param.h.

MFC after:	2 weeks.
Sponsored by:	gandi.net (BSD Day Taiwan)
This commit is contained in:
araujo 2016-07-30 07:04:46 +00:00
parent 380003ac33
commit 941cecd070

View File

@ -220,10 +220,10 @@ struct _kwinfo {
"(POSIX legacy)" } /* compat */
};
#define NKWINFO (sizeof(kwinfo)/sizeof(kwinfo[0]))
#define NKWINFO (nitems(kwinfo))
const char *boguslocales[] = { "UTF-8" };
#define NBOGUS (sizeof(boguslocales)/sizeof(boguslocales[0]))
#define NBOGUS (nitems(boguslocales))
int
main(int argc, char *argv[])