]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
rgw: initialize variable before call
authorYehuda Sadeh <yehuda@inktank.com>
Wed, 5 Feb 2014 23:19:51 +0000 (15:19 -0800)
committerSage Weil <sage@inktank.com>
Fri, 7 Feb 2014 16:43:47 +0000 (08:43 -0800)
Need to initialize the truncated variable, as we sometimes ignore error
response (e.g., with ENOENT), and in such cases we can't expect it to be
set.

Signed-off-by: Yehuda Sadeh <yehuda@inktank.com>
(cherry picked from commit 9ecf3467a3efc071954c4f69a23b51e677742c1f)

src/rgw/rgw_bucket.cc

index 6394e5f0ce995fca6d0188357d4c055b2870de87..9827bad309c9e3a195f698dab84ad5b09b68d861 100644 (file)
@@ -51,7 +51,7 @@ int rgw_read_user_buckets(RGWRados *store, string user_id, RGWUserBuckets& bucke
   bufferlist header;
   list<cls_user_bucket_entry> entries;
 
-  bool truncated;
+  bool truncated = false;
   string m = marker;
 
   uint64_t total = 0;