diff options
Diffstat (limited to 'contrib/epee/include/console_handler.h')
-rw-r--r-- | contrib/epee/include/console_handler.h | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/contrib/epee/include/console_handler.h b/contrib/epee/include/console_handler.h index 0e22a971c..6e7efd1d7 100644 --- a/contrib/epee/include/console_handler.h +++ b/contrib/epee/include/console_handler.h @@ -63,7 +63,8 @@ namespace epee ~async_stdin_reader() { - stop(); + try { stop(); } + catch (...) { /* ignore */ } } #ifdef HAVE_READLINE @@ -351,8 +352,11 @@ eof: std::string command; bool get_line_ret = m_stdin_reader.get_line(command); - if (!m_running || m_stdin_reader.eos()) + if (!m_running) + break; + if (m_stdin_reader.eos()) { + MGINFO("EOF on stdin, exiting"); break; } if (!get_line_ret) |