}
// This handles the case mentioned above: if the full CNAME chain leading to the answer was
// constructed from the cache, indicate that.
- if (fromCache != nullptr && haveFinalAnswer(qname, qtype, res, ret)) {
+ if (fromCache != nullptr && *fromCache == false && haveFinalAnswer(qname, qtype, res, ret)) {
*fromCache = true;
}
return res;
}
}
}
- if (fromCache != nullptr && haveFinalAnswer(qname, qtype, res, ret)) {
+ if (fromCache != nullptr && *fromCache == false && haveFinalAnswer(qname, qtype, res, ret)) {
*fromCache = true;
}
return res;