Skip to content

Commit f871817

Browse files
committed
fix(linux_routing.go): choose first rt_tables file
The rt_tables list is already in an ordered form in terms of priority. Once one is found, it should be considered the optimal one and stop looking for additional tables.
1 parent 4cafcdd commit f871817

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

pkg/utils/linux_routing.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,7 @@ func RouteTableAdd(tableNumber int, tableName string) error {
3737
continue
3838
}
3939
rtTablesLoc = possibleLoc
40+
break
4041
}
4142
if rtTablesLoc == "" {
4243
return fmt.Errorf("did not find rt_tables in any of the expected locations: %s", rtTablesFileName)

0 commit comments

Comments
 (0)