]> git.ozlabs.org Git - ccan/commitdiff
tally: Adapt tally_num to Samba coding conventions
authorVolker Lendecke <vl@samba.org>
Wed, 10 Aug 2011 17:46:37 +0000 (19:46 +0200)
committerRusty Russell <rusty@rustcorp.com.au>
Wed, 31 Aug 2011 01:09:11 +0000 (10:39 +0930)
(Imported from SAMBA commit 3f67063dfab1a7add95da5157206ccebb2f75df8)

ccan/tally/tally.c

index 28a66a9f7fa0ebf384c62d69de8b04b396f71cad..52bd4e11b903b661360390bd1c96dc34a875ed2b 100644 (file)
@@ -156,8 +156,9 @@ void tally_add(struct tally *tally, ssize_t val)
 size_t tally_num(const struct tally *tally)
 {
        size_t i, num = 0;
 size_t tally_num(const struct tally *tally)
 {
        size_t i, num = 0;
-       for (i = 0; i < tally->buckets; i++)
+       for (i = 0; i < tally->buckets; i++) {
                num += tally->counts[i];
                num += tally->counts[i];
+       }
        return num;
 }
 
        return num;
 }