]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
rgw: return correct bucket missing error when needed
authorYehuda Sadeh <yehuda@hq.newdream.net>
Thu, 25 Aug 2011 18:25:19 +0000 (11:25 -0700)
committerYehuda Sadeh <yehuda@hq.newdream.net>
Thu, 25 Aug 2011 18:25:19 +0000 (11:25 -0700)
src/rgw/rgw_rados.cc

index 6c5cdec2d1f5b7cfc15853490e7150221567c25d..f9bc8e6c5a2895fbfa18c15942acb5eb74b22576 100644 (file)
@@ -1416,6 +1416,8 @@ int RGWRados::get_bucket_id(rgw_bucket& bucket, uint64_t *bucket_id)
 {
   librados::IoCtx io_ctx;
   int r = open_bucket_ctx(bucket, io_ctx);
+  if (r == -ENOENT)
+    r = -ERR_NO_SUCH_BUCKET;
   if (r < 0)
     return r;