const ConstRRsetPtr& rrset, const bool dnssec)
{
/// Is this RRset already in the list of RRsets added to the message?
- std::vector<const AbstractRRset*>::iterator i =
+ const std::vector<const AbstractRRset*>::const_iterator i =
std::find_if(added_.begin(), added_.end(),
- std::bind1st(Query::RRsetInserter::isSameKind(),
+ std::bind1st(Query::RRsetInserter::IsSameKind(),
rrset.get()));
if (i == added_.end()) {
// No - add it to both the message and the list of RRsets processed.
class RRsetInserter {
public:
// \brief RRset comparison functor.
- struct isSameKind : public std::binary_function<
+ struct IsSameKind : public std::binary_function<
const isc::dns::AbstractRRset*,
const isc::dns::AbstractRRset*,
bool> {
<< cname_nxdom_txt // 7(1)
<< cname_out_txt; // 8(1)
rrset_vector.clear();
- masterLoad(ss, Name("example.com."), RRClass::IN(), loadRRsetVectorCallback);
+ masterLoad(ss, Name("example.com."), RRClass::IN(),
+ loadRRsetVectorCallback);
}
TEST_F(QueryTest, DuplicateNameRemoval) {
EXPECT_FALSE(rrset_p.isSameKind(rrset_z));
}
-
-// Utility function to create an add an RRset to a vector of RRsets for the
-// "less" test. It's only purpose is to allow the RRset creation to be
-// written with arguments in an order that reflects the RRset ordering.
-void
-addRRset(std::vector<ConstRRsetPtr>& vec, const RRType& rrtype,
- const RRClass& rrclass, const char* rrname)
-{
- vec.push_back(ConstRRsetPtr(new RRset(Name(rrname), rrclass, rrtype,
- RRTTL(3600))));
-}
-
// Note: although the next two tests are essentially the same and used common
// test code, they use different test data: the MessageRenderer produces
// compressed wire data whereas the OutputBuffer does not.