Browse Source

ignore empty

dev
BreakWa11 9 years ago
parent
commit
2f8517190c
  1. 3
      shadowsocks/common.py

3
shadowsocks/common.py

@ -297,7 +297,8 @@ class PortRange(object):
try: try:
int_range = item.split('-') int_range = item.split('-')
if len(int_range) == 1: if len(int_range) == 1:
self.range.add(int(item)) if item:
self.range.add(int(item))
elif len(int_range) == 2: elif len(int_range) == 2:
int_range[0] = int(int_range[0]) int_range[0] = int(int_range[0])
int_range[1] = int(int_range[1]) int_range[1] = int(int_range[1])

Loading…
Cancel
Save