summaryrefslogtreecommitdiff
path: root/Lib/uu.py
diff options
context:
space:
mode:
authorTim Peters <tim.peters@gmail.com>2001-07-11 04:08:49 +0000
committerTim Peters <tim.peters@gmail.com>2001-07-11 04:08:49 +0000
commitbce5516b12d57ce8d6c6bef97211b94c793a279a (patch)
treebc6348b5ab86b95bca7b43910420ced847410d5e /Lib/uu.py
parent2fb1b3f6a3f4d0079ad96d6e2d0a421b57034b9a (diff)
downloadcpython-bce5516b12d57ce8d6c6bef97211b94c793a279a.tar.gz
SF patch #440144: Tests and minor bugfix for uu module
decode(): While writing tests for uu.py, Nick Mathewson discovered that the 'Truncated input file' exception could never get raised, because its "if not str:" test was actually testing the builtin function "str", not the local string vrbl "s" as intended. Bugfix candidate.
Diffstat (limited to 'Lib/uu.py')
-rwxr-xr-xLib/uu.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/Lib/uu.py b/Lib/uu.py
index 334d436cd6..11a4e83f91 100755
--- a/Lib/uu.py
+++ b/Lib/uu.py
@@ -135,7 +135,7 @@ def decode(in_file, out_file=None, mode=None):
sys.stderr.write("Warning: %s\n" % str(v))
out_file.write(data)
s = in_file.readline()
- if not str:
+ if not s:
raise Error, 'Truncated input file'
def test():