From 0e8b29bc0eadae7e7a7ce9a2f072f4abd3576a80 Mon Sep 17 00:00:00 2001 From: Dan Goodliffe Date: Sat, 14 Feb 2015 17:40:45 +0000 Subject: Add all provided endpoints to the service proxy --- netfs/fuse/fuse.cpp | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/netfs/fuse/fuse.cpp b/netfs/fuse/fuse.cpp index 43a10c4..7f90710 100644 --- a/netfs/fuse/fuse.cpp +++ b/netfs/fuse/fuse.cpp @@ -76,9 +76,11 @@ NetFS::FuseApp::connectToService() if (e == fc->Resources.end()) { throw std::runtime_error("No such resource: " + resourceName); } - const std::string & ep = e->second->Endpoints.front(); - auto proxyAddr = e->second->ServiceIdentity + ":" + ep; + auto proxyAddr = e->second->ServiceIdentity; + for (const auto & ep : e->second->Endpoints) { + proxyAddr += ":" + ep; + } service = NetFS::ServicePrx::checkedCast(ic->stringToProxy(proxyAddr)); if (!service) { throw std::runtime_error("Invalid service proxy: " + proxyAddr); -- cgit v1.2.3