diff options
author | Benjamin Peterson <benjamin@python.org> | 2018-07-06 20:41:06 -0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-07-06 20:41:06 -0700 |
commit | b0274f2cddd36b49fe5080efbe160277ef546471 (patch) | |
tree | 6a13b9a5c333d79953a0d14af161c9b278c3b78c /Python/pymath.c | |
parent | e25399b40cd15620e77c9ad2ed24549006ae9b47 (diff) | |
download | cpython-git-b0274f2cddd36b49fe5080efbe160277ef546471.tar.gz |
closes bpo-34056: Always return bytes from _HackedGetData.get_data(). (GH-8130)
* Always return bytes from _HackedGetData.get_data().
Ensure the imp.load_source shim always returns bytes by reopening the file in
binary mode if needed. Hash-based pycs have to receive the source code in bytes.
It's tempting to change imp.get_suffixes() to always return 'rb' as a mode, but
that breaks some stdlib tests and likely 3rdparty code, too.
Diffstat (limited to 'Python/pymath.c')
0 files changed, 0 insertions, 0 deletions