File tree Expand file tree Collapse file tree 1 file changed +7
-5
lines changed Expand file tree Collapse file tree 1 file changed +7
-5
lines changed Original file line number Diff line number Diff line change @@ -738,14 +738,16 @@ function fixup_default_gateway($gateways_status, $gateways_arr)
738
738
if (empty ($ upgw ) && $ gwsttng [$ gwname ]['friendlyiface ' ] != "lan " &&
739
739
(isset ($ gwsttng ['monitor_disable ' ]) || !stristr ($ gateways_status [$ gwname ]['status ' ], "down " ))) {
740
740
$ upgw = $ gwname ;
741
- }
742
- if (!$ dfltgwup && !empty ($ upgw )) {
743
- // switch gateway
744
- $ dfltgwname = $ upgw ;
745
- break ;
741
+ if (!$ dfltgwup ) {
742
+ break ;
743
+ }
746
744
}
747
745
}
748
746
}
747
+ if (!$ dfltgwup && !empty ($ upgw )) {
748
+ // switch gateway
749
+ $ dfltgwname = $ upgw ;
750
+ }
749
751
if ($ gateways_arr [$ dfltgwname ]['gateway ' ] == "dynamic " ) {
750
752
if ($ ipprotocol == 'inet ' ) {
751
753
$ gwip = get_interface_gateway ($ gateways_arr [$ dfltgwname ]['friendlyiface ' ]);
You can’t perform that action at this time.
0 commit comments