increase default timeout, fix flag arguments
This commit is contained in:
parent
34e401b9a4
commit
e562fdc4bb
1 changed files with 5 additions and 2 deletions
|
@ -46,7 +46,7 @@ def main():
|
||||||
'interface': 'default',
|
'interface': 'default',
|
||||||
'gateway_address': '',
|
'gateway_address': '',
|
||||||
'lan_address': '',
|
'lan_address': '',
|
||||||
'timeout': 1,
|
'timeout': 30,
|
||||||
|
|
||||||
'HOST': SSDP_HOST,
|
'HOST': SSDP_HOST,
|
||||||
'ST': UPNP_ORG_IGD,
|
'ST': UPNP_ORG_IGD,
|
||||||
|
@ -58,7 +58,10 @@ def main():
|
||||||
command = None
|
command = None
|
||||||
for arg in args:
|
for arg in args:
|
||||||
if arg.startswith("--"):
|
if arg.startswith("--"):
|
||||||
k, v = arg.split("=")
|
if "=" in arg:
|
||||||
|
k, v = arg.split("=")
|
||||||
|
else:
|
||||||
|
k, v = arg, True
|
||||||
k = k.lstrip('--')
|
k = k.lstrip('--')
|
||||||
options[k] = v
|
options[k] = v
|
||||||
else:
|
else:
|
||||||
|
|
Loading…
Reference in a new issue