cmd/containerboot: don't parse empty subnet routes (#10738)

Updates#cleanup

Signed-off-by: Irbe Krumina <irbe@tailscale.com>
This commit is contained in:
Irbe Krumina 2024-01-04 12:17:15 +00:00 committed by GitHub
parent 5a2eb26db3
commit 3a9450bc06
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -756,7 +756,7 @@ func ensureIPForwarding(root, clusterProxyTarget, tailnetTargetiP, tailnetTarget
if tailnetTargetFQDN != "" {
v4Forwarding = true
}
if routes != nil {
if routes != nil && *routes != "" {
for _, route := range strings.Split(*routes, ",") {
cidr, err := netip.ParsePrefix(route)
if err != nil {