diff options
author | stijn <stinos@zoho.com> | 2015-05-28 14:20:31 +0200 |
---|---|---|
committer | Paul Sokolovsky <pfalcon@users.sourceforge.net> | 2015-05-30 13:38:17 +0300 |
commit | 100004eeaf6c24f6c1b6e009ea60c991e29a8692 (patch) | |
tree | 56cf12aeee650f47a670877cca5890447c8e42a1 | |
parent | 6a664cb11484a5ccdb0163c9628d56d5039db7c6 (diff) | |
download | micropython-100004eeaf6c24f6c1b6e009ea60c991e29a8692.tar.gz micropython-100004eeaf6c24f6c1b6e009ea60c991e29a8692.zip |
unix: Print an extra newline to the output on ctrl-D
This assures the terminal prints it's prompt on a fresh line instead of
appending it to the uPy prompt after exit.
-rw-r--r-- | unix/input.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/unix/input.c b/unix/input.c index d41487c7ef..9baa342b94 100644 --- a/unix/input.c +++ b/unix/input.c @@ -52,6 +52,7 @@ char *prompt(char *p) { vstr_clear(&vstr); if (ret == CHAR_CTRL_D) { // EOF + printf("\n"); return NULL; } else { printf("\n"); |