diff options
author | Libor Peltan <libor.peltan@nic.cz> | 2024-06-20 09:34:29 +0200 |
---|---|---|
committer | Daniel Salzman <daniel.salzman@nic.cz> | 2024-09-01 18:34:26 +0200 |
commit | 2fdadb4eb94469b9246a67c7d43b51223842fe2f (patch) | |
tree | a932384c8bd6203525262aabcb120986c985dffa | |
parent | Merge branch 'kxdpgun_query_fix' into 'master' (diff) | |
download | knot-2fdadb4eb94469b9246a67c7d43b51223842fe2f.tar.xz knot-2fdadb4eb94469b9246a67c7d43b51223842fe2f.zip |
ctl/zone-ksk-submitted: avoid deadlock on DNSSEC event when frozen...
knotc zone-ksk-submitted actually triggers two operations:
1) modification of KSK's metadata
2) re-signing of the zone when called in multithreaded CTL, it might happen
that knotc zone-begin arrives between those and if a third comand needs
to lock it all, it could cause deadlock
-rw-r--r-- | src/knot/ctl/commands.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/knot/ctl/commands.c b/src/knot/ctl/commands.c index 56cdfbfd7..3d0b30428 100644 --- a/src/knot/ctl/commands.c +++ b/src/knot/ctl/commands.c @@ -817,8 +817,8 @@ static int zone_ksk_sbm_confirm(zone_t *zone, _unused_ ctl_args_t *args) conf_val_t val = conf_zone_get(conf(), C_DNSSEC_SIGNING, zone->name); if (ret == KNOT_EOK && conf_bool(&val)) { - // NOT zone_events_schedule_user(), intentionally! - ret = schedule_trigger(zone, args, ZONE_EVENT_DNSSEC, false); + // NOT zone_events_schedule_user() or schedule_trigger(), intentionally! + zone_events_schedule_now(zone, ZONE_EVENT_DNSSEC); } return ret; |