[Inteproxy-commits] r276 - in trunk: . inteproxy
scm-commit@wald.intevation.org
scm-commit at wald.intevation.org
Mon Sep 20 21:46:59 CEST 2010
Author: bh
Date: 2010-09-20 21:46:56 +0200 (Mon, 20 Sep 2010)
New Revision: 276
Removed:
trunk/inteproxy/proxyconnection.py
Modified:
trunk/ChangeLog
Log:
* inteproxy/proxyconnection.py: Removed. It's no longer used.
Modified: trunk/ChangeLog
===================================================================
--- trunk/ChangeLog 2010-09-20 19:44:57 UTC (rev 275)
+++ trunk/ChangeLog 2010-09-20 19:46:56 UTC (rev 276)
@@ -1,5 +1,9 @@
2010-09-20 Bernhard Herzog <bh at intevation.de>
+ * inteproxy/proxyconnection.py: Removed. It's no longer used.
+
+2010-09-20 Bernhard Herzog <bh at intevation.de>
+
Make inteproxy/proxyconnection.py completely obsolete.
* inteproxy/httpconnection.py (parse_netloc, default_ports):
Deleted: trunk/inteproxy/proxyconnection.py
===================================================================
--- trunk/inteproxy/proxyconnection.py 2010-09-20 19:44:57 UTC (rev 275)
+++ trunk/inteproxy/proxyconnection.py 2010-09-20 19:46:56 UTC (rev 276)
@@ -1,38 +0,0 @@
-# Copyright (C) 2008, 2009, 2010 by Intevation GmbH
-#
-# Based on code from
-# http://aspn.activestate.com/ASPN/Cookbook/Python/Recipe/456195 which
-# is Copyright (C) 2006 by Alessandro Budai
-#
-# This software may be used and distributed according to the terms
-# of the Python License 2.3 or newer, see http://www.python.org/license
-
-"""
-Variant of httplib.HTTPConnection that connects through a proxy using
-the http CONNECT method (that can be used to proxy SSL connections).
-"""
-
-import urllib
-
-
-default_ports = {'http' : 80, 'https' : 443}
-
-
-def parse_netloc(scheme, netloc):
- """Parses netloc and returns (hostname, port).
-
- If the netloc string doesn't contain a port, the default port of
- scheme (either 'http' or 'https') is used. If the port cannot be
- determined, a ValueError is raise.
- """
- host, port = urllib.splitport(netloc)
- if port is None:
- port = default_ports.get(scheme)
- if port is None:
- raise ValueError("Cannot determine port for URL scheme %r"
- % scheme)
- else:
- port = int(port)
- return host, port
-
-
More information about the Inteproxy-commits
mailing list