[Python-checkins] python/dist/src/Lib urllib2.py,1.78,1.79

jlgijsbers at users.sourceforge.net jlgijsbers at users.sourceforge.net
Sun Jan 9 06:51:52 CET 2005


Update of /cvsroot/python/python/dist/src/Lib
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv16010

Modified Files:
	urllib2.py 
Log Message:
Patch #1095362: replace hardcoded test for POST/GET with call to get_method,
removing some duplication and gaining some flexibility in the process.


Index: urllib2.py
===================================================================
RCS file: /cvsroot/python/python/dist/src/Lib/urllib2.py,v
retrieving revision 1.78
retrieving revision 1.79
diff -u -d -r1.78 -r1.79
--- urllib2.py	22 Dec 2004 14:27:19 -0000	1.78
+++ urllib2.py	9 Jan 2005 05:51:49 -0000	1.79
@@ -859,7 +859,7 @@
             entdig = None
 
         A1 = "%s:%s:%s" % (user, realm, pw)
-        A2 = "%s:%s" % (req.has_data() and 'POST' or 'GET',
+        A2 = "%s:%s" % (req.get_method(),
                         # XXX selector: what about proxies and full urls
                         req.get_selector())
         if qop == 'auth':



More information about the Python-checkins mailing list