From 4aaa1dd526013e01775b1b07e757a33b328659a6 Mon Sep 17 00:00:00 2001 From: RaNaN Date: Mon, 14 Feb 2011 19:14:10 +0100 Subject: finished cli --- module/remote/thriftbackend/ThriftClient.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'module/remote/thriftbackend/ThriftClient.py') diff --git a/module/remote/thriftbackend/ThriftClient.py b/module/remote/thriftbackend/ThriftClient.py index c5beec96e..d5c203cf0 100644 --- a/module/remote/thriftbackend/ThriftClient.py +++ b/module/remote/thriftbackend/ThriftClient.py @@ -57,6 +57,10 @@ class ThriftClient: correct = self.client.login(user, password) finally: self.socket.setTimeout(None) + elif e.args and e.args[0] == 32: + raise NoConnection + else: + raise if not correct: self.transport.close() @@ -77,7 +81,7 @@ class ThriftClient: if __name__ == "__main__": - client = ThriftClient(user="User", password="pyloadweb") + client = ThriftClient(user="User", password="") print client.getServerVersion() print client.statusServer() -- cgit v1.2.3