summaryrefslogtreecommitdiffstats
path: root/Lib/uu.py
diff options
context:
space:
mode:
Diffstat (limited to 'Lib/uu.py')
-rwxr-xr-xLib/uu.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/Lib/uu.py b/Lib/uu.py
index 084d9f3..18a9f79 100755
--- a/Lib/uu.py
+++ b/Lib/uu.py
@@ -72,12 +72,12 @@ def encode(in_file, out_file, name=None, mode=None):
#
# Write the data
#
- out_file.write('begin %o %s\n' % ((mode & 0o777),name))
+ out_file.write(('begin %o %s\n' % ((mode & 0o777), name)).encode("ascii"))
data = in_file.read(45)
while len(data) > 0:
- out_file.write(str(binascii.b2a_uu(data), "ascii"))
+ out_file.write(binascii.b2a_uu(data))
data = in_file.read(45)
- out_file.write(' \nend\n')
+ out_file.write(b' \nend\n')
def decode(in_file, out_file=None, mode=None, quiet=0):