]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
rgw: Remove logically dead code 52436/head
authorVedansh Bhartia <vedanshbhartia@gmail.com>
Sun, 16 Jul 2023 05:06:22 +0000 (10:36 +0530)
committerVedansh Bhartia <vedanshbhartia@gmail.com>
Sun, 16 Jul 2023 07:02:20 +0000 (12:32 +0530)
Signed-off-by: Vedansh Bhartia <vedanshbhartia@gmail.com>
src/rgw/driver/rados/rgw_reshard.cc
src/rgw/rgw_sal_dbstore.cc

index 31eff5312df4812e2d70fe30bb0400fa1fc5cc82..4369bc8a05c8bcf8b4cff8741b676c35fb675f28 100644 (file)
@@ -1303,9 +1303,6 @@ int RGWReshard::process_single_logshard(int logshard_num, const DoutPrefixProvid
 
     for(auto& entry: entries) { // logshard entries
       process_entry(entry, max_entries, dpp, y);
-      if (ret < 0) {
-        return ret;
-      }
 
       Clock::time_point now = Clock::now();
       if (logshard_lock.should_renew(now)) {
index df6330552e758f48c828840cd7130768f60391eb..9886bd5b590962727e62abb3a728f3457cf25902 100644 (file)
@@ -1329,7 +1329,6 @@ namespace rgw::sal {
                        rgw_zone_set *zones_trace, bool *canceled,
                        optional_yield y)
   {
-    int ret = 0;
     /* XXX: same as AtomicWriter..consolidate code */
     parent_op.meta.mtime = mtime;
     parent_op.meta.delete_at = delete_at;
@@ -1341,9 +1340,6 @@ namespace rgw::sal {
     /* XXX: handle accounted size */
     accounted_size = total_data_size;
 
-    if (ret < 0)
-      return ret;
-
     RGWUploadPartInfo info;
     info.num = part_num;
     info.etag = etag;
@@ -1354,7 +1350,7 @@ namespace rgw::sal {
 
     DB::Object op_target(store->getDB(),
         meta_obj->get_bucket()->get_info(), meta_obj->get_obj());
-    ret = op_target.add_mp_part(dpp, info);
+    auto ret = op_target.add_mp_part(dpp, info);
     if (ret < 0) {
       return ret == -ENOENT ? -ERR_NO_SUCH_UPLOAD : ret;
     }