]> git.ipfire.org Git - thirdparty/dhcpcd.git/commitdiff
When MTU is less than 576 we now ignore it instead of setting the MTU to 576.
authorRoy Marples <roy@marples.name>
Fri, 23 Mar 2007 10:02:02 +0000 (10:02 +0000)
committerRoy Marples <roy@marples.name>
Fri, 23 Mar 2007 10:02:02 +0000 (10:02 +0000)
ChangeLog
dhcp.c

index 46da53184fae24e96ab311b1125f8e1353a461f3..4a7e6a6c2a4e1798a708327988f02b23c5441aa2 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,4 +1,5 @@
 When we get an invalid length for a DHCP option, try and continue anyway.
+When MTU is less than 576 we now ignore it instead of setting the MTU to 576.
 
 dhcpcd-3.0.16
 RFC 2131 is full of confusion regarding MTU it seems as the effective minimum
diff --git a/dhcp.c b/dhcp.c
index 95ec84b72113f0fdee998442d80c0e23cb5f44fb..d1c42201f9970370c8e53e57dc934827c7bce298 100644 (file)
--- a/dhcp.c
+++ b/dhcp.c
@@ -611,8 +611,8 @@ int parse_dhcpmessage (dhcp_t *dhcp, const dhcpmessage_t *message)
             In practise it's 576 (minimum maximum message size) */
          if (dhcp->mtu < MTU_MIN)
            {
-             logger (LOG_ERR, "given MTU %d is too low, minium is %d", dhcp->mtu, MTU_MIN);
-             dhcp->mtu = MTU_MIN;
+             logger (LOG_DEBUG, "MTU %d is too low, minium is %d; ignoring", dhcp->mtu, MTU_MIN);
+             dhcp->mtu = 0;
            }
          break;