Permalink
Browse files

Merge pull request #38 from rkern/fix/file-read-encoding

BUG: Read source files as bytes.
  • Loading branch information...
rkern committed Nov 4, 2015
2 parents a2f484a + 0aff122 commit e8cffaa11f6ca12c79edb344993126d2efebc8b3
Showing with 5 additions and 1 deletion.
  1. +4 −0 README.rst
  2. +1 −1 kernprof.py
View
@@ -355,6 +355,10 @@ Bugs and pull requested can be submitted on GitHub_.
Changes
=======
+1.1
+~~~
+* BUG: Read source files as bytes.
+
1.0
~~~
* ENH: `kernprof.py` is now installed as `kernprof`.
View
@@ -31,7 +31,7 @@
exec_ = getattr(builtins, "exec")
def execfile(filename, globals=None, locals=None):
- with open(filename) as f:
+ with open(filename, 'rb') as f:
exec_(compile(f.read(), filename, 'exec'), globals, locals)
# =====================================

0 comments on commit e8cffaa

Please sign in to comment.