TS-32: Exit on Ctrl-D on non-readline systems.

This commit is contained in:
Paul Fenwick 2017-02-21 15:11:26 +13:00 committed by Paul Beckingham
parent d5bd17cff0
commit 87d05ed28a

View file

@ -84,7 +84,10 @@ const std::string getResponse (const std::string& prompt)
std::cout << prompt;
std::getline (std::cin, response);
if (std::cin.eof () == 1)
{
response = "<EOF>";
std::cout << "\n";
}
#endif
return response;