summaryrefslogtreecommitdiff
path: root/cpp/src/Ice/Reference.cpp
diff options
context:
space:
mode:
authorJose <jose@zeroc.com>2016-01-11 04:02:47 -0500
committerJose <jose@zeroc.com>2016-01-11 04:02:47 -0500
commit889d3abfa4cacd7c30178561c25342f93387de32 (patch)
tree602e9e4281ae3b764d9ceaacd25505337ff4116d /cpp/src/Ice/Reference.cpp
parentC++11 fix Exception::ice_clone to use exception_ptr (diff)
downloadice-889d3abfa4cacd7c30178561c25342f93387de32.tar.bz2
ice-889d3abfa4cacd7c30178561c25342f93387de32.tar.xz
ice-889d3abfa4cacd7c30178561c25342f93387de32.zip
C++11 build fixes for gcc 4.8 on rhel7
Diffstat (limited to 'cpp/src/Ice/Reference.cpp')
-rw-r--r--cpp/src/Ice/Reference.cpp8
1 files changed, 6 insertions, 2 deletions
diff --git a/cpp/src/Ice/Reference.cpp b/cpp/src/Ice/Reference.cpp
index bc635c8e0a9..737d4bdbfe6 100644
--- a/cpp/src/Ice/Reference.cpp
+++ b/cpp/src/Ice/Reference.cpp
@@ -1354,8 +1354,12 @@ IceInternal::RoutableReference::operator==(const Reference& r) const
return false;
}
#ifdef ICE_CPP11_MAPPING
- if(!equal(_endpoints.begin(), _endpoints.end(), rhs->_endpoints.begin(), rhs->_endpoints.end(),
- Ice::TargetEquals<shared_ptr<EndpointI>>()))
+ //
+ // TODO: With C++14 we could use the vesion that receives four iterators and we don't need to explicitly
+ // check the sizesa are equal.
+ //
+ if(_endpoints.size() != rhs->_endpoints.size() ||
+ !equal(_endpoints.begin(), _endpoints.end(), rhs->_endpoints.begin(), Ice::TargetEquals<shared_ptr<EndpointI>>()))
#else
if(_endpoints != rhs->_endpoints)
#endif