From: Libor Peltan Date: Sun, 14 Aug 2022 07:58:47 +0000 (+0200) Subject: replan: replan the expire if the zone expired during the load X-Git-Tag: v3.3.dev~7^2 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=2d22a8aada8ca90dca56c1e2a1abe6a086d140e5;p=thirdparty%2Fknot-dns.git replan: replan the expire if the zone expired during the load --- diff --git a/src/knot/events/replan.c b/src/knot/events/replan.c index e69e67fd7c..b7d70e4eea 100644 --- a/src/knot/events/replan.c +++ b/src/knot/events/replan.c @@ -113,13 +113,13 @@ void replan_from_timers(conf_t *conf, zone_t *zone) time_t expire_pre = TIME_IGNORE; time_t expire = TIME_IGNORE; - if (zone_is_slave(conf, zone) && !zone_expired(zone)) { + if (zone_is_slave(conf, zone) && zone->contents != NULL) { expire_pre = TIME_CANCEL; expire = zone->timers.next_expire; } time_t flush = TIME_IGNORE; - if (!zone_is_slave(conf, zone) || !zone_expired(zone)) { + if (!zone_is_slave(conf, zone) || zone->contents != NULL) { conf_val_t val = conf_zone_get(conf, C_ZONEFILE_SYNC, zone->name); int64_t sync_timeout = conf_int(&val); if (sync_timeout > 0) {