update last poll time when the interface poll frequency is reached

In the IPv6-only network, when the download time exceeds 30 seconds,
compared with REF, the IPv4 download peak rate of DUT begins to decay
with time.

The reason is: during the period from "reading ipv6 packets through
packet socket to "sending the translated ipv4 packets to tun device
through raw socket", clatd consumes more time than normal. And clatd
spent most of it time on the function: ipv6_address_changed().

Test: builds and boots, phone call, internet under wifi and
    cellular data, lab FTP download test under 464xlat

Bug: 167648019
Signed-off-by: Rocco Yue <rocco.yue@mediatek.com>
Signed-off-by: Maciej Żenczykowski <maze@google.com>

Original change: https://android-review.googlesource.com/c/platform/external/android-clat/+/1419090

Change-Id: I815361b799c444a1094601e83a9b6a2d9fabf521
Merged-In: I815361b799c444a1094601e83a9b6a2d9fabf521
diff --git a/clatd.c b/clatd.c
index 7063215..422cded 100644
--- a/clatd.c
+++ b/clatd.c
@@ -426,7 +426,8 @@
     }
 
     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;
       }