diff options
author | Stephen Morris <stephen@isc.org> | 2014-12-15 15:45:28 +0100 |
---|---|---|
committer | Stephen Morris <stephen@isc.org> | 2014-12-15 15:45:28 +0100 |
commit | 32f06c29c0ab3ce02455c04f23034951162d265f (patch) | |
tree | 82ec2da69f91cd58c4c5c19acf288c38a7b9046b /src/lib/dhcpsrv/cfg_hosts.cc | |
parent | [master] Added ChangeLog for #3628. (diff) | |
download | kea-32f06c29c0ab3ce02455c04f23034951162d265f.tar.xz kea-32f06c29c0ab3ce02455c04f23034951162d265f.zip |
[3643] Fix problem on Ubuntu and NetBSD Builds
Both Ubuntu and NetBSD builds fail because of what appears to be an error
trying to the use "equal_range" method of one of the classes associated with
the Boost multi-index container. The cause is uncertain - other systems
build successfully, so the problem might no lie here, e.g. it could be in
the compiler. This fix attempts to side-step the problem by modifying the
affected files so as not to use this method.
Diffstat (limited to 'src/lib/dhcpsrv/cfg_hosts.cc')
-rw-r--r-- | src/lib/dhcpsrv/cfg_hosts.cc | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/lib/dhcpsrv/cfg_hosts.cc b/src/lib/dhcpsrv/cfg_hosts.cc index 8bb17f3cc3..4b7936815d 100644 --- a/src/lib/dhcpsrv/cfg_hosts.cc +++ b/src/lib/dhcpsrv/cfg_hosts.cc @@ -50,13 +50,13 @@ void CfgHosts::getAllInternal(const std::vector<uint8_t>& identifier, const Host::IdentifierType& identifier_type, Storage& storage) const { - // Search for the Host using the identifier and identifier type as a - // composite key. + // Use the identifier and identifier type as a composite key. const HostContainerIndex0& idx = hosts_.get<0>(); - std::pair<HostContainerIndex0::iterator, HostContainerIndex0::iterator> r = - idx.equal_range(boost::make_tuple(identifier, identifier_type)); + boost::tuple<const std::vector<uint8_t>, const Host::IdentifierType> t = + boost::make_tuple(identifier, identifier_type); + // Append each Host object to the storage. - for (HostContainerIndex0::iterator host = r.first; host != r.second; + for (HostContainerIndex0::iterator host = idx.lower_bound(t); host != idx.upper_bound(t); ++host) { storage.push_back(*host); } |