Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 9 additions & 1 deletion lib/srv/desktop/discovery.go
Original file line number Diff line number Diff line change
Expand Up @@ -208,8 +208,16 @@ func (s *WindowsService) lookupDesktop(ctx context.Context, hostname string) ([]
hostname, resolverName, err)
}

ch <- addrs
// even though we requested "ip4" it's possible to get IPv4
// addresses mapped to IPv6 addresses, so we unmap them here
result := make([]netip.Addr, 0, len(addrs))
for _, addr := range addrs {
if addr.Is4() || addr.Is4In6() {
result = append(result, addr.Unmap())
}
}

ch <- result
}()
return ch
}
Expand Down