mirror of
https://github.com/v2fly/v2ray-core.git
synced 2026-05-04 19:49:08 -04:00
rename IPNet to IPNetTable
This commit is contained in:
@@ -180,11 +180,11 @@ func (v *CIDRMatcher) Apply(ctx context.Context) bool {
|
||||
}
|
||||
|
||||
type IPv4Matcher struct {
|
||||
ipv4net *v2net.IPNet
|
||||
ipv4net *v2net.IPNetTable
|
||||
onSource bool
|
||||
}
|
||||
|
||||
func NewIPv4Matcher(ipnet *v2net.IPNet, onSource bool) *IPv4Matcher {
|
||||
func NewIPv4Matcher(ipnet *v2net.IPNetTable, onSource bool) *IPv4Matcher {
|
||||
return &IPv4Matcher{
|
||||
ipv4net: ipnet,
|
||||
onSource: onSource,
|
||||
|
||||
@@ -17,7 +17,7 @@ func (r *Rule) Apply(ctx context.Context) bool {
|
||||
}
|
||||
|
||||
func cidrToCondition(cidr []*CIDR, source bool) (Condition, error) {
|
||||
ipv4Net := v2net.NewIPNet()
|
||||
ipv4Net := v2net.NewIPNetTable()
|
||||
ipv6Cond := NewAnyCondition()
|
||||
hasIpv6 := false
|
||||
|
||||
|
||||
Reference in New Issue
Block a user