Commit d9fda268 authored by Michal 'vorner' Vaner's avatar Michal 'vorner' Vaner
Browse files

[trac553] Fix the wildcard check routine

It crashed when the checked code didn't provide any answer.
parent 17f874bb
......@@ -296,6 +296,11 @@ public:
if (check_answer) {
EXPECT_EQ(answer, find_result.rrset);
} else if (check_wild_answer) {
ASSERT_NE(ConstRRsetPtr(), answer) <<
"Wrong test, don't check for wild names if you expect"
"empty answer";
ASSERT_NE(ConstRRsetPtr(), find_result.rrset) <<
"No answer found";
RdataIteratorPtr expectedIt(answer->getRdataIterator());
RdataIteratorPtr gotIt(answer->getRdataIterator());
while (!expectedIt->isLast() && !gotIt->isLast()) {
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment