summaryrefslogtreecommitdiffstats
path: root/Lib/binhex.py
diff options
context:
space:
mode:
authorRonald Oussoren <ronaldoussoren@mac.com>2020-11-01 09:08:48 (GMT)
committerGitHub <noreply@github.com>2020-11-01 09:08:48 (GMT)
commit2165cea548f961b308050f30d1f042a377651d44 (patch)
tree77d97dfecbba2440090fe4628724bf85bebc855d /Lib/binhex.py
parentd3b4e068077dd26927ae7485bd0303e09d962c02 (diff)
downloadcpython-2165cea548f961b308050f30d1f042a377651d44.zip
cpython-2165cea548f961b308050f30d1f042a377651d44.tar.gz
cpython-2165cea548f961b308050f30d1f042a377651d44.tar.bz2
bpo-29566: binhex.binhex now consitently writes MacOS 9 line endings. (GH-23059)
[bpo-29566]() notes that binhex.binhex uses inconsistent line endings (both Unix and MacOS9 line endings are used). This PR changes this to use the MacOS9 line endings everywhere.
Diffstat (limited to 'Lib/binhex.py')
-rw-r--r--Lib/binhex.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/Lib/binhex.py b/Lib/binhex.py
index 9559f46..ace5217 100644
--- a/Lib/binhex.py
+++ b/Lib/binhex.py
@@ -117,12 +117,12 @@ class _Hqxcoderengine:
first = 0
while first <= len(self.hqxdata) - self.linelen:
last = first + self.linelen
- self.ofp.write(self.hqxdata[first:last] + b'\n')
+ self.ofp.write(self.hqxdata[first:last] + b'\r')
self.linelen = LINELEN
first = last
self.hqxdata = self.hqxdata[first:]
if force:
- self.ofp.write(self.hqxdata + b':\n')
+ self.ofp.write(self.hqxdata + b':\r')
def close(self):
if self.data: