From 72d9eb2aefa8d13135a87b52163554e214abebf3 Mon Sep 17 00:00:00 2001 From: joss17 Date: Wed, 13 Jan 2010 21:27:07 +0000 Subject: [PATCH] solve a bug in the load list af connect mgr git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@2020 b45a01b8-16f6-495d-af2f-9b41ad6348cc --- libretroshare/src/pqi/p3connmgr.cc | 17 +++++++++-------- 1 file changed, 9 insertions(+), 8 deletions(-) diff --git a/libretroshare/src/pqi/p3connmgr.cc b/libretroshare/src/pqi/p3connmgr.cc index 23295f70f..7edc21e07 100644 --- a/libretroshare/src/pqi/p3connmgr.cc +++ b/libretroshare/src/pqi/p3connmgr.cc @@ -2997,14 +2997,15 @@ bool p3ConnectMgr::loadList(std::list load) vitem->print(std::cerr, 10); std::cerr << std::endl; #endif - if(vitem->tlvkvs.pairs.front().key == "USE_EXTR_IP_FINDER") - { - use_extr_addr_finder = (vitem->tlvkvs.pairs.front().value == "TRUE") ; - std::cerr << "setting use_extr_addr_finder to " << use_extr_addr_finder << std::endl ; - } else if (vitem->tlvkvs.pairs.front().key == "ALLOW_TUNNEL_CONNECTION") - { - allow_tunnel_connection = (vitem->tlvkvs.pairs.front().value == "TRUE") ; - std::cerr << "setting allow_tunnel_connection to " << allow_tunnel_connection << std::endl ; + std::list::iterator kit; + for(kit = vitem->tlvkvs.pairs.begin(); kit != vitem->tlvkvs.pairs.end(); kit++) { + if(kit->key == "USE_EXTR_IP_FINDER") { + use_extr_addr_finder = (kit->value == "TRUE"); + std::cerr << "setting use_extr_addr_finder to " << use_extr_addr_finder << std::endl ; + } else if (kit->key == "ALLOW_TUNNEL_CONNECTION") { + allow_tunnel_connection = (kit->value == "TRUE"); + std::cerr << "setting allow_tunnel_connection to " << allow_tunnel_connection << std::endl ; + } } }