[Python-checkins] python/dist/src/Lib/distutils/command upload.py, 1.8, 1.9

pje@users.sourceforge.net pje at users.sourceforge.net
Thu Jul 7 17:36:24 CEST 2005


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

Modified Files:
	upload.py 
Log Message:
Fix "upload" command garbling and truncating files on Windows.  If it's a
binary file, use 'rb'!


Index: upload.py
===================================================================
RCS file: /cvsroot/python/python/dist/src/Lib/distutils/command/upload.py,v
retrieving revision 1.8
retrieving revision 1.9
diff -u -d -r1.8 -r1.9
--- upload.py	28 Mar 2005 01:08:03 -0000	1.8
+++ upload.py	7 Jul 2005 15:36:21 -0000	1.9
@@ -71,7 +71,7 @@
                   dry_run=self.dry_run)
 
         # Fill in the data
-        content = open(filename).read()
+        content = open(filename,'rb').read()
         data = {
             ':action':'file_upload',
             'protcol_version':'1',



More information about the Python-checkins mailing list