mirror of
https://github.com/Control-D-Inc/ctrld.git
synced 2026-05-27 12:52:27 +02:00
cmd/cli: ensure DNS goroutines terminated before self-uninstall
Otherwise, these goroutines could mess up with what resetDNS function do, reverting DHCP DNS settings to ctrld listeners.
This commit is contained in:
committed by
Cuong Manh Le
parent
79476add12
commit
5af3ec4f7b
@@ -863,7 +863,7 @@ func (p *prog) doSelfUninstall(answer *dns.Msg) {
|
||||
p.checkingSelfUninstall = true
|
||||
_, err := controld.FetchResolverConfig(cdUID, rootCmd.Version, cdDev)
|
||||
logger.Debug().Msg("maximum number of refused queries reached, checking device status")
|
||||
selfUninstall(err, p, logger)
|
||||
selfUninstallCheck(err, p, logger)
|
||||
|
||||
if err != nil {
|
||||
logger.Warn().Err(err).Msg("could not fetch resolver config")
|
||||
|
||||
Reference in New Issue
Block a user