summaryrefslogtreecommitdiff
path: root/Lib/cmd.py
diff options
context:
space:
mode:
authorJesus Cea <jcea@jcea.es>2011-12-06 20:46:04 +0100
committerJesus Cea <jcea@jcea.es>2011-12-06 20:46:04 +0100
commita94b578431725ea50381e7d31ff5580741593398 (patch)
tree25dc70edaf5800664c8301eeb883d25926cc2f67 /Lib/cmd.py
parent9a38863d8ce5444be29d2e20341b28147b94f33a (diff)
downloadcpython-git-a94b578431725ea50381e7d31ff5580741593398.tar.gz
Close #13500: Hitting EOF gets cmd.py into a infinite EOF on return loop
Diffstat (limited to 'Lib/cmd.py')
-rw-r--r--Lib/cmd.py2
1 files changed, 2 insertions, 0 deletions
diff --git a/Lib/cmd.py b/Lib/cmd.py
index 29ea4608e7..ae7f12ef18 100644
--- a/Lib/cmd.py
+++ b/Lib/cmd.py
@@ -209,6 +209,8 @@ class Cmd:
if cmd is None:
return self.default(line)
self.lastcmd = line
+ if line == 'EOF' :
+ self.lastcmd = ''
if cmd == '':
return self.default(line)
else: