[bugzilla-gnome-org-extensions] splinter_proxy.py: Python-2.4 compat for xmlrpclib.Transport.__init__
- From: Krzesimir Nowak <krnowak src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [bugzilla-gnome-org-extensions] splinter_proxy.py: Python-2.4 compat for xmlrpclib.Transport.__init__
- Date: Thu, 20 Nov 2014 22:21:16 +0000 (UTC)
commit f21c05e1b164fe2e5301da34dabf5165d0368be8
Author: Owen W. Taylor <otaylor fishsoup net>
Date: Mon Sep 28 14:37:38 2009 -0400
splinter_proxy.py: Python-2.4 compat for xmlrpclib.Transport.__init__
Python 2.4 doesn't have xmlrpclib.Transport.__init__, so check
for existence before calling it.
proxy/splinter_proxy.py | 3 ++-
1 files changed, 2 insertions(+), 1 deletions(-)
---
diff --git a/proxy/splinter_proxy.py b/proxy/splinter_proxy.py
index 7ac785f..e70c0d7 100755
--- a/proxy/splinter_proxy.py
+++ b/proxy/splinter_proxy.py
@@ -306,7 +306,8 @@ def check_login_headers(headers):
# subclass.
class LoginTransport(xmlrpclib.Transport):
def __init__(self, scheme, hostname, port):
- xmlrpclib.Transport.__init__(self)
+ if hasattr(xmlrpclib.Transport, '__init__'):
+ xmlrpclib.Transport.__init__(self)
self.scheme = scheme
self.hostname = hostname
self.port = port
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]