]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
test/crimson: remove unnecessary local variable 41396/head
authorKefu Chai <kchai@redhat.com>
Wed, 19 May 2021 10:21:05 +0000 (18:21 +0800)
committerKefu Chai <kchai@redhat.com>
Thu, 20 May 2021 05:10:03 +0000 (13:10 +0800)
to return the return value of "make_unique<>()" is more readable, and more
consistent with other part of this source file.

Signed-off-by: Kefu Chai <kchai@redhat.com>
src/test/crimson/seastore/transaction_manager_test_state.h

index 9a1c51fdcbb7e57f5fbd8ee523d018646a832851..a0146c45d74f49e584b9fa818175b038a7fce9d1 100644 (file)
@@ -79,13 +79,12 @@ auto get_transaction_manager(
 
   journal->set_segment_provider(&*segment_cleaner);
 
-  auto ret = std::make_unique<TransactionManager>(
+  return std::make_unique<TransactionManager>(
     segment_manager,
     std::move(segment_cleaner),
     std::move(journal),
     std::move(cache),
     std::move(lba_manager));
-  return ret;
 }
 
 auto get_seastore(SegmentManagerRef sm) {