summaryrefslogtreecommitdiffstats
path: root/clatd.c
diff options
context:
space:
mode:
Diffstat (limited to 'clatd.c')
-rw-r--r--clatd.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/clatd.c b/clatd.c
index 7063215..422cded 100644
--- a/clatd.c
+++ b/clatd.c
@@ -426,7 +426,8 @@ void event_loop(struct tun_data *tunnel) {
}
time_t now = time(NULL);
- if (last_interface_poll < (now - INTERFACE_POLL_FREQUENCY)) {
+ if (now >= (last_interface_poll + INTERFACE_POLL_FREQUENCY)) {
+ last_interface_poll = now;
if (ipv6_address_changed(Global_Clatd_Config.native_ipv6_interface)) {
break;
}