]> git.ipfire.org Git - thirdparty/knot-resolver.git/commitdiff
ta_update: abort update if keyset is no longer managed
authorTomas Krizek <tomas.krizek@nic.cz>
Tue, 19 Mar 2019 15:20:11 +0000 (16:20 +0100)
committerPetr Špaček <petr.spacek@nic.cz>
Thu, 4 Apr 2019 12:18:58 +0000 (14:18 +0200)
modules/ta_update/ta_update.lua

index 4792f85ad1e3bc69db00204e7ceea36394807358..4c0b47624fb188e4991407b423512f0d4cb30509 100644 (file)
@@ -136,6 +136,10 @@ end
 -- Update existing keyset; return true if successful.
 local function update(keyset, new_keys)
        if not new_keys then return false end
+       if not keyset.managed then
+               -- this may happen due to race condition during testing in CI (refesh time < query time)
+               return false
+       end
 
        -- Filter TAs to be purged from the keyset (KeyRem), in three steps
        -- 1: copy TAs to be kept to `keepset`