Skip to content

Commit

Permalink
feat: remove IsPrivate from safeSocketControl (#2672)
Browse files Browse the repository at this point in the history
Signed-off-by: Gaius <[email protected]>
  • Loading branch information
gaius-qi authored Aug 25, 2023
1 parent b1834c6 commit 0c4d779
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion pkg/net/http/http.go
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ func safeSocketControl(network string, address string, conn syscall.RawConn) err
return fmt.Errorf("host %s is invalid", host)
}

if !ip.IsGlobalUnicast() || ip.IsPrivate() {
if !ip.IsGlobalUnicast() {
return fmt.Errorf("ip %s is invalid", ip.String())
}

Expand Down

0 comments on commit 0c4d779

Please sign in to comment.