From e562fdc4bbe5b9fcd383e896c8d22ce5ccf854ce Mon Sep 17 00:00:00 2001 From: Jack Robison Date: Thu, 11 Oct 2018 17:29:16 -0400 Subject: [PATCH] increase default timeout, fix flag arguments --- aioupnp/__main__.py | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/aioupnp/__main__.py b/aioupnp/__main__.py index d219692..f16e490 100644 --- a/aioupnp/__main__.py +++ b/aioupnp/__main__.py @@ -46,7 +46,7 @@ def main(): 'interface': 'default', 'gateway_address': '', 'lan_address': '', - 'timeout': 1, + 'timeout': 30, 'HOST': SSDP_HOST, 'ST': UPNP_ORG_IGD, @@ -58,7 +58,10 @@ def main(): command = None for arg in args: if arg.startswith("--"): - k, v = arg.split("=") + if "=" in arg: + k, v = arg.split("=") + else: + k, v = arg, True k = k.lstrip('--') options[k] = v else: