Skip to content

Commit

Permalink
Merge branch 'output' into tcp_algo
Browse files Browse the repository at this point in the history
  • Loading branch information
YairSlobodin1 committed Sep 2, 2024
2 parents 524956c + 9692f06 commit 002a952
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion pkg/io/confio/sg.go
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ func sgRemote(nameToSGRemoteRef map[string]*vpcv1.SecurityGroupRuleRemoteSecurit
st := rule.Remote.String()
switch t := rule.Remote.(type) {
case *netset.IPBlock:
if t.Size() == 1 { // single IP address
if ipString := t.ToIPAddressString(); ipString != "" { // single IP address
return &vpcv1.SecurityGroupRuleRemoteIP{
Address: &st,
}
Expand Down
2 changes: 1 addition & 1 deletion pkg/io/csvio/sg.go
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ func sgPort(p interval.Interval) string {
func sgRemoteType(t ir.RemoteType) string {
switch t := t.(type) {
case *netset.IPBlock:
if t.Size() == 1 {
if ipString := t.ToIPAddressString(); ipString != "" {
return "IP address"
}
return "CIDR block"
Expand Down
2 changes: 1 addition & 1 deletion pkg/io/mdio/sg.go
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ func sGPort(p interval.Interval) string {
func sGRemoteType(t ir.RemoteType) string {
switch t := t.(type) {
case *netset.IPBlock:
if t.Size() == 1 {
if ipString := t.ToIPAddressString(); ipString != "" {
return "IP address"
}
return "CIDR block"
Expand Down

0 comments on commit 002a952

Please sign in to comment.