engine: mac: fallback properly
Some checks failed
Quality check / Static analysis (push) Has been cancelled
Quality check / Tests (push) Has been cancelled

This commit is contained in:
2026-02-11 12:14:53 +05:30
parent 1b6a5ba309
commit ef00ca1793

View File

@@ -164,7 +164,7 @@ func (r *sourceMACResolver) refreshARPCache(now time.Time) {
func (r *sourceMACResolver) refreshNDPCache(now time.Time) {
m, ok := readNeighborCacheFile("/proc/net/ndisc_cache")
if !ok {
if !ok || len(m) == 0 {
// Fallback for environments without /proc/net/ndisc_cache.
m = readIPv6NeighCommand()
}