aboutsummaryrefslogtreecommitdiff
path: root/contrib/epee/src/readline_buffer.cpp
diff options
context:
space:
mode:
authorJethro Grassie <jtg@xtrabass.com>2017-06-20 09:22:55 -0400
committerJethro Grassie <jtg@xtrabass.com>2017-06-24 07:34:56 -0400
commitfdccf7e6c3a90af62f4979b39227e8ac23f0ecbb (patch)
tree862035e387bf8a4b6f18180dd45535091e0864ca /contrib/epee/src/readline_buffer.cpp
parentMerge pull request #2111 (diff)
downloadmonero-fdccf7e6c3a90af62f4979b39227e8ac23f0ecbb.tar.xz
Add readline improvements
Color prompt now working and no reprompting on exit command.
Diffstat (limited to '')
-rw-r--r--contrib/epee/src/readline_buffer.cpp7
1 files changed, 5 insertions, 2 deletions
diff --git a/contrib/epee/src/readline_buffer.cpp b/contrib/epee/src/readline_buffer.cpp
index 2d17103b3..d38afd296 100644
--- a/contrib/epee/src/readline_buffer.cpp
+++ b/contrib/epee/src/readline_buffer.cpp
@@ -168,8 +168,11 @@ static int handle_enter(int x, int y)
}
free(line);
- rl_set_prompt(last_prompt.c_str());
- rl_redisplay();
+ if(last_line != "exit")
+ {
+ rl_set_prompt(last_prompt.c_str());
+ rl_redisplay();
+ }
rl_done = 1;
return 0;