From e0b59e91d12e077c0f09476a5a57b88b3b217032 Mon Sep 17 00:00:00 2001 From: Sage Weil Date: Sun, 12 Aug 2018 13:20:13 -0500 Subject: [PATCH] auth: clean up cap parse error messages Consistent formatted. Drop newline. Signed-off-by: Sage Weil --- src/mds/MDSAuthCaps.cc | 5 +++-- src/mon/MonCap.cc | 7 ++++--- src/osd/OSDCap.cc | 4 ++-- 3 files changed, 9 insertions(+), 7 deletions(-) diff --git a/src/mds/MDSAuthCaps.cc b/src/mds/MDSAuthCaps.cc index ffa06f60e97..949ac62c0c4 100644 --- a/src/mds/MDSAuthCaps.cc +++ b/src/mds/MDSAuthCaps.cc @@ -335,8 +335,9 @@ bool MDSAuthCaps::parse(CephContext *c, std::string_view str, ostream *err) grants.clear(); if (err) - *err << "MDSAuthCaps parse failed, stopped at '" << std::string(iter, end) - << "' of '" << str << "'\n"; + *err << "mds capability parse failed, stopped at '" + << std::string(iter, end) + << "' of '" << str << "'"; return false; } } diff --git a/src/mon/MonCap.cc b/src/mon/MonCap.cc index ad1e61a8332..1724a10ae52 100644 --- a/src/mon/MonCap.cc +++ b/src/mon/MonCap.cc @@ -613,10 +613,11 @@ bool MonCap::parse(const string& str, ostream *err) if (err) { if (iter != end) - *err << "moncap parse failed, stopped at '" << std::string(iter, end) - << "' of '" << str << "'\n"; + *err << "mon capability parse failed, stopped at '" + << std::string(iter, end) + << "' of '" << str << "'"; else - *err << "moncap parse failed, stopped at end of '" << str << "'\n"; + *err << "mon capability parse failed, stopped at end of '" << str << "'"; } return false; diff --git a/src/osd/OSDCap.cc b/src/osd/OSDCap.cc index bbbe4c54e3b..0dc074ebcaa 100644 --- a/src/osd/OSDCap.cc +++ b/src/osd/OSDCap.cc @@ -535,8 +535,8 @@ bool OSDCap::parse(const string& str, ostream *err) grants.clear(); if (err) - *err << "osdcap parse failed, stopped at '" << std::string(iter, end) - << "' of '" << str << "'\n"; + *err << "osd capability parse failed, stopped at '" << std::string(iter, end) + << "' of '" << str << "'"; return false; }