summaryrefslogtreecommitdiffstats
path: root/Lib/tarfile.py
diff options
context:
space:
mode:
Diffstat (limited to 'Lib/tarfile.py')
-rw-r--r--Lib/tarfile.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/Lib/tarfile.py b/Lib/tarfile.py
index 082f361..d7c1500 100644
--- a/Lib/tarfile.py
+++ b/Lib/tarfile.py
@@ -186,7 +186,7 @@ def nti(s):
# itn() below.
if s[0] != chr(0200):
try:
- n = int(nts(s) or "0", 8)
+ n = int(nts(s).strip() or "0", 8)
except ValueError:
raise InvalidHeaderError("invalid header")
else: