From 6193255446a17601acc31693069c05c2ade47ea9 Mon Sep 17 00:00:00 2001 From: Gunnar Beutner Date: Fri, 17 Oct 2014 20:47:48 +0200 Subject: [PATCH] Add missing locks refs #7251 --- lib/cli/objectlistcommand.cpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/lib/cli/objectlistcommand.cpp b/lib/cli/objectlistcommand.cpp index 9c5a40351..db8e2b3b1 100644 --- a/lib/cli/objectlistcommand.cpp +++ b/lib/cli/objectlistcommand.cpp @@ -162,6 +162,8 @@ void ObjectListCommand::PrintProperties(std::ostream& fp, const Dictionary::Ptr& int offset = 2; + ObjectLock olock(props); + BOOST_FOREACH(const Dictionary::Pair& kv, props) { String key = kv.first; Value val = kv.second; @@ -195,6 +197,8 @@ void ObjectListCommand::PrintHints(std::ostream& fp, const Dictionary::Ptr& debu Array::Ptr messages = debug_hints->Get("messages"); + ObjectLock olock(messages); + BOOST_FOREACH(const Value& msg, messages) { PrintHint(fp, msg, indent); } -- 2.40.0