mirror of
https://git.deluge-torrent.org/deluge
synced 2025-04-21 12:04:51 +00:00
Gracefully handle ctrl-d, and don't exit on blank command.
This commit is contained in:
parent
47406335ac
commit
ca3f08690e
1 changed files with 7 additions and 3 deletions
|
@ -291,9 +291,13 @@ class NullUI:
|
|||
readline.read_init_file()
|
||||
|
||||
while True:
|
||||
inp = raw_input("> ")
|
||||
if len(inp) == 0: break
|
||||
inp = inp.strip().split(" ")
|
||||
try:
|
||||
inp = raw_input("> ").strip()
|
||||
except:
|
||||
inp = 'quit'
|
||||
|
||||
if len(inp) == 0: continue
|
||||
inp = inp.split(" ")
|
||||
|
||||
print ""
|
||||
cmd = inp[0]
|
||||
|
|
Loading…
Add table
Reference in a new issue