1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-25 16:37:35 +00:00

LookupServer: Introduce DNSName

This is a wrapper around a string representing a domain name (such as
"example.com"). It never has a trailing dot.

For now, this class doesn't do much except wrap the raw string. Subsequent
commits will add or move more functionality to it.
This commit is contained in:
Sergey Bugaev 2021-02-14 15:02:02 +03:00 committed by Andreas Kling
parent de811faf55
commit ae1e82fd2f
9 changed files with 117 additions and 38 deletions

View file

@ -29,7 +29,7 @@
namespace LookupServer {
DNSAnswer::DNSAnswer(const String& name, u16 type, u16 class_code, u32 ttl, const String& record_data)
DNSAnswer::DNSAnswer(const DNSName& name, u16 type, u16 class_code, u32 ttl, const String& record_data)
: m_name(name)
, m_type(type)
, m_class_code(class_code)