This commit is contained in:
blueloveTH 2023-04-26 12:36:33 +08:00
parent 4ccf4d304b
commit a2b25f6735

View File

@ -23,6 +23,7 @@ inline std::string getline(bool* eof=nullptr) {
std::string output;
output.resize(length);
WideCharToMultiByte(CP_UTF8, 0, wideInput.c_str(), (int)wideInput.length(), &output[0], length, NULL, NULL);
if(output.size() && output[output.size()-1] == '\r') output.pop_back();
return output;
}