Skip to content

Commit 3e52dda

Browse files
committed
Fix hysteria port error
1 parent d7222fa commit 3e52dda

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

hysteria/client.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -142,15 +142,15 @@ func ParsePorts(serverPorts []string) ([]uint16, error) {
142142
if subIndex > 0 {
143143
start, err = strconv.ParseUint(portRange[:subIndex], 10, 16)
144144
if err != nil {
145-
return nil, E.Cause(err, E.Cause(err, "bad port range: ", portRange))
145+
return nil, E.Cause(err, "bad port range: ", portRange)
146146
}
147147
}
148148
if subIndex == len(portRange)-1 {
149149
end = math.MaxUint16
150150
} else {
151151
end, err = strconv.ParseUint(portRange[subIndex+1:], 10, 16)
152152
if err != nil {
153-
return nil, E.Cause(err, E.Cause(err, "bad port range: ", portRange))
153+
return nil, E.Cause(err, "bad port range: ", portRange)
154154
}
155155
}
156156
for i := start; i <= end; i++ {

0 commit comments

Comments
 (0)