From: Volker Lendecke Date: Thu, 2 Feb 2012 16:49:22 +0000 (+0100) Subject: s3: Use ARRAY_SIZE in bsd_attr_list X-Git-Tag: tevent-0.9.15~73 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=bbde29824179fc78ee923ccd24e4039b96eb866d;p=thirdparty%2Fsamba.git s3: Use ARRAY_SIZE in bsd_attr_list --- diff --git a/source3/lib/system.c b/source3/lib/system.c index 821dd8d957f..a308014f464 100644 --- a/source3/lib/system.c +++ b/source3/lib/system.c @@ -1797,7 +1797,7 @@ static ssize_t bsd_attr_list (int type, extattr_arg arg, char *list, size_t size int i, t, len; char *buf; /* Iterate through extattr(2) namespaces */ - for(t = 0; t < (sizeof(extattr)/sizeof(extattr[0])); t++) { + for(t = 0; t < ARRAY_SIZE(extattr); t++) { switch(type) { #if defined(HAVE_EXTATTR_LIST_FILE) case 0: