From 9e90c0131029ab5a7800ad3a0f13c8ac942638a1 Mon Sep 17 00:00:00 2001 From: "Adam C. Emerson" Date: Wed, 29 Aug 2018 15:37:17 -0400 Subject: [PATCH] cephfs: Do not catch polymorphic exception by value Signed-off-by: Adam C. Emerson --- src/tools/cephfs/JournalFilter.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/tools/cephfs/JournalFilter.cc b/src/tools/cephfs/JournalFilter.cc index 3b30ffa092f..266d7fccb57 100644 --- a/src/tools/cephfs/JournalFilter.cc +++ b/src/tools/cephfs/JournalFilter.cc @@ -226,7 +226,7 @@ int JournalFilter::parse_args( } else if (!type.compare("purge_queue")) { purge_action = PurgeItem::str_to_type(arg_str); } - } catch (std::out_of_range) { + } catch (const std::out_of_range&) { derr << "Invalid event type '" << arg_str << "'" << dendl; return -EINVAL; } -- 2.39.5