Skip to content

Commit d63c23a

Browse files
vadorovskymurali-reddy
authored andcommitted
proxy: Fix ineffassign error (#447)
`out` variable content after executing `ip route list table` was never used.
1 parent abfb705 commit d63c23a

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

pkg/controllers/proxy/network_services_controller.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1677,13 +1677,13 @@ func (ln *linuxNetworking) setupRoutesForExternalIPForDSR(serviceInfoMap service
16771677
}
16781678
}
16791679

1680-
out, err := exec.Command("ip", "route", "list", "table", externalIPRouteTableId).Output()
1680+
_, err = exec.Command("ip", "route", "list", "table", externalIPRouteTableId).Output()
16811681
if err != nil {
16821682
return errors.New("Failed to verify required routing table for external IP's exists. " +
16831683
"Failed to setup policy routing required for DSR due to " + err.Error())
16841684
}
16851685

1686-
out, err = exec.Command("ip", "rule", "list").Output()
1686+
out, err := exec.Command("ip", "rule", "list").Output()
16871687
if err != nil {
16881688
return errors.New("Failed to verify if `ip rule add prio 32765 from all lookup external_ip` exists due to: " + err.Error())
16891689
}

0 commit comments

Comments
 (0)