Fix checksum support to be compatible with Windows.

R=maruel@chromium.org
AUTHOR=cmp@chromium.org

Review URL: https://chromiumcodereview.appspot.com/9956052

git-svn-id: svn://svn.chromium.org/boto@4 4f2e627c-b00b-48dd-b1fb-2c643665b734
diff --git a/README.chromium b/README.chromium
new file mode 100644
index 0000000..14982ac
--- /dev/null
+++ b/README.chromium
@@ -0,0 +1,22 @@
+URL: http://github.com/boto/boto
+Version: 2.1.1
+License: MIT License
+
+This is a forked copy of boto v2.1.1.
+
+
+Fix checksum support to be compatible with Windows.
+See http://bugs.python.org/issue1735418 for more info.
+
+index 5492e14..d7d2aa0 100644
+--- a/boto/s3/resumable_download_handler.py
++++ b/boto/s3/resumable_download_handler.py
+@@ -220,7 +220,7 @@ class ResumableDownloadHandler(object):
+         gsutil runs), and the user could change some of the file and not
+         realize they have inconsistent data.
+         """
+-        fp = open(file_name, 'r')
++        fp = open(file_name, 'rb')
+         if key.bucket.connection.debug >= 1:
+             print 'Checking md5 against etag.'
+         hex_md5 = key.compute_md5(fp)[0]
diff --git a/boto/s3/resumable_download_handler.py b/boto/s3/resumable_download_handler.py
index 5492e14..d7d2aa0 100644
--- a/boto/s3/resumable_download_handler.py
+++ b/boto/s3/resumable_download_handler.py
@@ -220,7 +220,7 @@
         gsutil runs), and the user could change some of the file and not
         realize they have inconsistent data.
         """
-        fp = open(file_name, 'r')
+        fp = open(file_name, 'rb')
         if key.bucket.connection.debug >= 1:
             print 'Checking md5 against etag.'
         hex_md5 = key.compute_md5(fp)[0]