diff options
author | Miss Islington (bot) <31488909+miss-islington@users.noreply.github.com> | 2019-06-12 04:50:11 -0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-06-12 04:50:11 -0700 |
commit | d561f848b235f2011a43b705d112055b92fa2366 (patch) | |
tree | 17367ffd5a657840af191bbedb1b99befbf8d38e /Misc | |
parent | 534136ac6790a701e24f364a9b7f1e34bf5f3ce7 (diff) | |
download | cpython-git-d561f848b235f2011a43b705d112055b92fa2366.tar.gz |
bpo-31829: Make protocol 0 pickles be loadable in text mode in Python 2. (GH-11859)
Escape ``\r``, ``\0`` and ``\x1a`` (end-of-file on Windows) in Unicode strings.
(cherry picked from commit 38ab7d4721b422547f7b46b9d68968863fa70573)
Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
Diffstat (limited to 'Misc')
-rw-r--r-- | Misc/NEWS.d/next/Library/2017-10-21-12-07-56.bpo-31829.6IhP-O.rst | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/Misc/NEWS.d/next/Library/2017-10-21-12-07-56.bpo-31829.6IhP-O.rst b/Misc/NEWS.d/next/Library/2017-10-21-12-07-56.bpo-31829.6IhP-O.rst new file mode 100644 index 0000000000..aefb8aec16 --- /dev/null +++ b/Misc/NEWS.d/next/Library/2017-10-21-12-07-56.bpo-31829.6IhP-O.rst @@ -0,0 +1,3 @@ +``\r``, ``\0`` and ``\x1a`` (end-of-file on Windows) are now escaped in +protocol 0 pickles of Unicode strings. This allows to load them without loss +from files open in text mode in Python 2. |