Move Console from Scheduler into Utils
[senf.git] / Utils / Console / Readline.cc
similarity index 98%
rename from Scheduler/Console/Readline.cc
rename to Utils/Console/Readline.cc
index 87efd87..4b7f724 100644 (file)
@@ -192,7 +192,8 @@ prefix_ void senf::console::detail::ReadlineClientReader::v_enablePrompt()
 
 prefix_ void senf::console::detail::ReadlineClientReader::v_translate(std::string & data)
 {
-    boost::replace_all(data, "\n", "\n\r");
+    boost::replace_all(data, "\n", "\r\n");
+    boost::replace_all(data, "\r", "\r\0");
     boost::replace_all(data, "\xff", "\xff\xff");
 }