diff options
author | Walter Purcaro <vuolter@gmail.com> | 2015-01-25 16:54:40 +0100 |
---|---|---|
committer | Walter Purcaro <vuolter@gmail.com> | 2015-01-25 16:54:40 +0100 |
commit | d95f42fd8aef58a1aa892a8540a7ec360540d90a (patch) | |
tree | f0db56cda24899a0b58794f104738bf90fca2607 /module/plugins/hooks | |
parent | [XFSHoster] Fixed #1078 (diff) | |
download | pyload-d95f42fd8aef58a1aa892a8540a7ec360540d90a.tar.xz |
[ClickAndLoad] Fix bad except
Diffstat (limited to 'module/plugins/hooks')
-rw-r--r-- | module/plugins/hooks/ClickAndLoad.py | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/module/plugins/hooks/ClickAndLoad.py b/module/plugins/hooks/ClickAndLoad.py index 682639750..c8e5e0e98 100644 --- a/module/plugins/hooks/ClickAndLoad.py +++ b/module/plugins/hooks/ClickAndLoad.py @@ -51,7 +51,7 @@ def create_connection(address, timeout=socket._GLOBAL_DEFAULT_TIMEOUT, sock.connect(sa) return sock - except error as _: + except socket.error, _: err = _ if sock is not None: sock.close() @@ -59,13 +59,13 @@ def create_connection(address, timeout=socket._GLOBAL_DEFAULT_TIMEOUT, if err is not None: raise err else: - raise error("getaddrinfo returns an empty list") + raise socket.error("getaddrinfo returns an empty list") class ClickAndLoad(Hook): __name__ = "ClickAndLoad" __type__ = "hook" - __version__ = "0.28" + __version__ = "0.29" __config__ = [("activated", "bool", "Activated" , True ), ("port" , "int" , "Port" , 9666 ), |