Revision c38de34b
Added by Renato Botelho almost 7 years ago
src/etc/inc/gwlb.inc | ||
---|---|---|
545 | 545 |
} |
546 | 546 |
|
547 | 547 |
function compare_gateway_order_configured($a, $b) { |
548 |
/* XXX WAN always has precedence */ |
|
549 |
if ($a['friendlyiface'] == "wan") { |
|
550 |
return -1; |
|
551 |
} elseif ($b['friendlyiface'] == "wan") { |
|
552 |
return 1; |
|
553 |
} |
|
554 |
|
|
548 | 555 |
if ($a['attribute'] === $b['attribute']) { |
549 | 556 |
if ($a['attribute'] === 'system') { |
550 | 557 |
$res = (($a['name'] < $b['name'])) ? -1 : 1; |
Also available in: Unified diff
Fix #8910: Restore older versions behaviour and consider 'wan' interface as primary default gateway