diff --git a/src/Mdns.csproj b/src/Mdns.csproj
index 656f577..f743d31 100644
--- a/src/Mdns.csproj
+++ b/src/Mdns.csproj
@@ -31,7 +31,7 @@
-
+
diff --git a/src/MulticastService.cs b/src/MulticastService.cs
index e59f3dd..c28c77e 100644
--- a/src/MulticastService.cs
+++ b/src/MulticastService.cs
@@ -39,7 +39,7 @@ public class MulticastService
IPEndPoint mdnsEndpoint;
// IP header (20 bytes for IPv4; 40 bytes for IPv6) and the UDP header(8 bytes).
const int packetOverhead = 48;
- const int maxDatagramSize = 9000;
+ const int maxDatagramSize = Message.MaxLength;
int maxPacketSize;
///