From 9e7af6b677853e0a5e56e05ffdc4e7c30bef8ff2 Mon Sep 17 00:00:00 2001 From: Ming-Hung Tsai Date: Sun, 19 Jun 2016 21:37:00 +0800 Subject: [PATCH] [metadata_counter] remove explicit try/catch when counting data space map Unlike metadata_index_store, the constructor of btree_index_store doesn't throw exceptions. --- thin-provisioning/metadata_counter.cc | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/thin-provisioning/metadata_counter.cc b/thin-provisioning/metadata_counter.cc index e36fde6..f6055f0 100644 --- a/thin-provisioning/metadata_counter.cc +++ b/thin-provisioning/metadata_counter.cc @@ -41,12 +41,10 @@ void thin_provisioning::count_space_maps(transaction_manager::ptr tm, } // Count the data space map (no-throw) - try { + { persistent_space_map::ptr data_sm = open_disk_sm(*tm, static_cast(&sb.data_space_map_root_)); data_sm->count_metadata(bc); - } catch (std::exception &e) { - cerr << e.what() << endl; } }