diff options
author | Jim Meyering <meyering@redhat.com> | 2009-05-17 13:01:37 +0200 |
---|---|---|
committer | Jim Meyering <meyering@redhat.com> | 2009-05-17 13:59:12 +0200 |
commit | 9b54961b13af78c4805076c6b6739cc282b53c5e (patch) | |
tree | 3200f1876e8907c56c49314e73f2c25caea4b095 | |
parent | 50ca12c28d2f0b3df73a026a1fecea294c4cb42c (diff) | |
download | coreutils-9b54961b13af78c4805076c6b6739cc282b53c5e.tar.xz |
maint: define ARRAY_CARDINALITY in system.h
* src/system.h (ARRAY_CARDINALITY): Define if not already defined.
-rw-r--r-- | src/system.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/system.h b/src/system.h index 5bc23b32f..74d86bbee 100644 --- a/src/system.h +++ b/src/system.h @@ -702,3 +702,7 @@ io_blksize (struct stat sb) } void usage (int status) ATTRIBUTE_NORETURN; + +#ifndef ARRAY_CARDINALITY +# define ARRAY_CARDINALITY(Array) (sizeof (Array) / sizeof *(Array)) +#endif |