diff --git a/rai/node/rpc.cpp b/rai/node/rpc.cpp index 7af596d0..2d7dd342 100755 --- a/rai/node/rpc.cpp +++ b/rai/node/rpc.cpp @@ -1476,7 +1476,9 @@ void rai::rpc_handler::peers () { std::stringstream text; text << i->first; - peers_l.push_back(boost::property_tree::ptree::value_type(text.str (), std::to_string (i->second))); + boost::property_tree::ptree entry; + entry.put (text.str (), std::to_string (i->second)); + peers_l.push_back (std::make_pair ("", entry)); } response_l.add_child ("peers", peers_l); response (response_l);