add a new ARRAY_SIZE macro and use it

Signed-off-by: Mike Frysinger <vapier@gentoo.org>
This commit is contained in:
Mike Frysinger committed 2012-05-06 01:17:30 -04:00
1 parent 3969cb2a85
commit 0813a80223
3 files changed
+6 -4

No files matched your search

+2
View File
@@ -46,6 +46,8 @@
# define _unused
#endif
#define ARRAY_SIZE(a) (sizeof(a) / sizeof((a)[0]))
/* Some libc implemntations don't have these */
#ifndef TAILQ_CONCAT
#define TAILQ_CONCAT(head1, head2, field) do { \