diff options
author | Georg Brandl <georg@python.org> | 2006-10-12 12:03:11 (GMT) |
---|---|---|
committer | Georg Brandl <georg@python.org> | 2006-10-12 12:03:11 (GMT) |
commit | 58bf57fa040741496cd4c53c85e3269a3e11af1b (patch) | |
tree | e9d353b5c6747509f88ea98e680f3984e9f1f343 | |
parent | ef11b1ab9cbbafd23b2be81bf933e58f6809d89e (diff) | |
download | cpython-58bf57fa040741496cd4c53c85e3269a3e11af1b.zip cpython-58bf57fa040741496cd4c53c85e3269a3e11af1b.tar.gz cpython-58bf57fa040741496cd4c53c85e3269a3e11af1b.tar.bz2 |
Fix tarfile depending on buggy int('1\0', base) behavior.
(backport from rev. 52313)
-rw-r--r-- | Lib/tarfile.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Lib/tarfile.py b/Lib/tarfile.py index 38cccae..8d5f021 100644 --- a/Lib/tarfile.py +++ b/Lib/tarfile.py @@ -144,7 +144,7 @@ def nti(s): # There are two possible encodings for a number field, see # itn() below. if s[0] != chr(0200): - n = int(s.rstrip(NUL) or "0", 8) + n = int(s.rstrip(NUL + " ") or "0", 8) else: n = 0L for i in xrange(len(s) - 1): |