net/dns: fix error wrapping for SetLinkDefaultRoute in resolved

Signed-off-by: Maxim Merzhanov <maksimmerzh@gmail.com>
This commit is contained in:
Maxim Merzhanov 2021-09-16 18:05:47 +03:00 committed by Brad Fitzpatrick
parent 3ea8cf9c62
commit d43fcd2f02
1 changed files with 1 additions and 1 deletions

View File

@ -176,7 +176,7 @@ func (m *resolvedManager) SetDNS(config OSConfig) error {
}
if call := m.resolved.CallWithContext(ctx, "org.freedesktop.resolve1.Manager.SetLinkDefaultRoute", 0, m.ifidx, len(config.MatchDomains) == 0); call.Err != nil {
return fmt.Errorf("setLinkDefaultRoute: %w", err)
return fmt.Errorf("setLinkDefaultRoute: %w", call.Err)
}
// Some best-effort setting of things, but resolved should do the