X-Git-Url: http://git.kpe.io/?p=ctsim.git;a=blobdiff_plain;f=tools%2Fctsimtext.cpp;h=e1695b127f666d8ab34a22ce2e811a1c05b6957a;hp=5a569c4d70b74429829826746587cd5e9375219c;hb=728543fba0d875b2977ea2b6562df1ee4a6af8f7;hpb=b6b7a4c68b20d0f86c8fb1095a166d4b93c3feba diff --git a/tools/ctsimtext.cpp b/tools/ctsimtext.cpp index 5a569c4..e1695b1 100644 --- a/tools/ctsimtext.cpp +++ b/tools/ctsimtext.cpp @@ -145,6 +145,10 @@ ctsimtext_main (int argc, char * argv[]) char* pszInputLine = new char [s_MaxLineLength+1]; std::cout << szPrompt; std::cin.getline (pszInputLine, s_MaxLineLength); + if (std::cin.eof()) { + std::cout << "\n"; + break; + } #ifdef DEBUG std::cout << "#" << pszInputLine << "#\n";