Add Port as a type

This commit is contained in:
V2Ray
2015-12-02 12:47:54 +01:00
parent e8e6cf1429
commit cee85bdf26
16 changed files with 125 additions and 98 deletions
+1 -1
View File
@@ -85,7 +85,7 @@ func (this *FieldRule) Apply(dest v2net.Destination) bool {
if this.Port != nil {
port := address.Port()
if port < this.Port.From() || port > this.Port.To() {
if port.Value() < this.Port.From().Value() || port.Value() > this.Port.To().Value() {
return false
}
}