]> git.ipfire.org Git - thirdparty/dhcpcd.git/commitdiff
Only use MRT if we have an MRT
authorRoy Marples <roy@marples.name>
Wed, 24 Jun 2015 14:44:18 +0000 (14:44 +0000)
committerRoy Marples <roy@marples.name>
Wed, 24 Jun 2015 14:44:18 +0000 (14:44 +0000)
dhcp6.c

diff --git a/dhcp6.c b/dhcp6.c
index 8fa48abdaee439975d90cd1f87b334aab80ce58d..d7c742bcfd4e63fa38fd5c5fb6d2d4bf4759ce42 100644 (file)
--- a/dhcp6.c
+++ b/dhcp6.c
@@ -1082,7 +1082,7 @@ dhcp6_sendmessage(struct interface *ifp, void (*callback)(void *))
                else
                        timespecadd(&state->RT, &RTprev, &state->RT);
 
-               if (state->RT.tv_sec > state->MRT) {
+               if (state->MRT != 0 && state->RT.tv_sec > state->MRT) {
                        RTprev.tv_sec = state->MRT;
                        RTprev.tv_nsec = 0;
                        state->RT.tv_sec = state->MRT;