always exit on empty command line

This commit is contained in:
Josh Holtrop 2011-01-03 08:27:08 -05:00
parent 4edabbdf3b
commit 7f5aef193d

8
dwtt
View File

@ -39,9 +39,13 @@ def main(argv):
while True: while True:
cmdline = doCmdWindow() cmdline = doCmdWindow()
cmd = Command(cmdline) if cmdline.strip() == '':
if not processCommand(cmd, ds):
break break
cmd = Command(cmdline)
res = processCommand(cmd, ds)
if type(res).__name__ == 'bool':
if not res:
break
def doCmdWindow(): def doCmdWindow():
c = CmdWindow() c = CmdWindow()