]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
crush/builder.c: reduce scope of oldsize in crush_add_bucket()
authorDanny Al-Gaaf <danny.al-gaaf@bisect.de>
Tue, 7 May 2013 15:26:33 +0000 (17:26 +0200)
committerDanny Al-Gaaf <danny.al-gaaf@bisect.de>
Fri, 10 May 2013 17:19:58 +0000 (19:19 +0200)
Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
src/crush/builder.c

index 3473704503d03b614d6f4ae7c3b9fe2098640d0d..2eb6ff5fc1e5531eed41d7177bbe527b1b537b32 100644 (file)
@@ -125,7 +125,6 @@ int crush_add_bucket(struct crush_map *map,
                     int id,
                     struct crush_bucket *bucket)
 {
-       int oldsize;
        int pos;
 
        /* find a bucket id */
@@ -135,7 +134,7 @@ int crush_add_bucket(struct crush_map *map,
 
        while (pos >= map->max_buckets) {
                /* expand array */
-               oldsize = map->max_buckets;
+               int oldsize = map->max_buckets;
                if (map->max_buckets)
                        map->max_buckets *= 2;
                else