Problem: Message::to_raw could only encode queries: It asserted the answer and authority counts were zero and never wrote those. So, a response — which carries answers — couldn’t be serialized at all. Fix: Write the answer and authority records as well — alongside the existing question and additional sections, and using the existing ResourceRecord::to_raw. Then drop the query-only assertions. The order matches the wire format: question, answer, authority, additional. |
||
|---|---|---|
| .. | ||
| CMakeLists.txt | ||
| Message.cpp | ||
| Message.h | ||
| Resolver.h | ||