Browse files

reading files with binary mode. this fixes an issue on windows.

fixes issue #189
  • Loading branch information...
1 parent 1b511bc commit fedb57e181a2b6b3fcd0d36a48faf9f34ebc609d @davidbrai davidbrai committed Jan 10, 2012
Showing with 1 addition and 1 deletion.
  1. +1 −1 compressor/filters/css_default.py
View
2 compressor/filters/css_default.py
@@ -62,7 +62,7 @@ def add_suffix(self, url):
if settings.COMPRESS_CSS_HASHING_METHOD == "mtime":
suffix = get_hashed_mtime(filename)
elif settings.COMPRESS_CSS_HASHING_METHOD == "hash":
- hash_file = open(filename)
+ hash_file = open(filename, 'rb')
try:
suffix = get_hexdigest(hash_file.read(), 12)
finally:

0 comments on commit fedb57e

Please sign in to comment.