chiark / gitweb /
resolved: use CLOCK_BOOTTIME instead of CLOCK_MONOTONIC when aging caches and timeing...
[elogind.git] / src / resolve / resolved-dns-transaction.c
index 92f7e4c5b1f118fbbd8bfe14385c8a0fe81e9184..faa1de9143a275b525d77b0a6f5aecbbb0ab5bcc 100644 (file)
@@ -515,7 +515,12 @@ int dns_transaction_go(DnsTransaction *t) {
                 return dns_transaction_go(t);
         }
 
-        r = sd_event_add_time(t->scope->manager->event, &t->timeout_event_source, CLOCK_MONOTONIC, now(CLOCK_MONOTONIC) + TRANSACTION_TIMEOUT_USEC(t->scope->protocol), 0, on_transaction_timeout, t);
+        r = sd_event_add_time(
+                        t->scope->manager->event,
+                        &t->timeout_event_source,
+                        clock_boottime_or_monotonic(),
+                        now(clock_boottime_or_monotonic()) + TRANSACTION_TIMEOUT_USEC(t->scope->protocol), 0,
+                        on_transaction_timeout, t);
         if (r < 0)
                 return r;