From 50d42bef49b9fcbc6bdd40e395ff1419b28cad0d Mon Sep 17 00:00:00 2001 From: Jason Dillaman Date: Fri, 14 Feb 2020 09:35:43 -0500 Subject: [PATCH] librbd: the journal SnapLimitEvent was not properly handled It was not being properly decoded since it was missing from the factory and it would output as an "Unknown" event code. Signed-off-by: Jason Dillaman --- src/librbd/journal/Types.cc | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/librbd/journal/Types.cc b/src/librbd/journal/Types.cc index ee919d35d7b54..d76a15e557cec 100644 --- a/src/librbd/journal/Types.cc +++ b/src/librbd/journal/Types.cc @@ -471,6 +471,9 @@ void EventEntry::decode(bufferlist::const_iterator& it) { case EVENT_TYPE_DEMOTE_PROMOTE: event = DemotePromoteEvent(); break; + case EVENT_TYPE_SNAP_LIMIT: + event = SnapLimitEvent(); + break; case EVENT_TYPE_UPDATE_FEATURES: event = UpdateFeaturesEvent(); break; @@ -831,6 +834,9 @@ std::ostream &operator<<(std::ostream &out, const EventType &type) { case EVENT_TYPE_DEMOTE_PROMOTE: out << "Demote/Promote"; break; + case EVENT_TYPE_SNAP_LIMIT: + out << "SnapLimit"; + break; case EVENT_TYPE_UPDATE_FEATURES: out << "UpdateFeatures"; break; -- 2.39.5