diff --git a/extensions/removerepeat.cpp b/extensions/removerepeat.cpp index a5c1b5c..c02919c 100644 --- a/extensions/removerepeat.cpp +++ b/extensions/removerepeat.cpp @@ -25,6 +25,7 @@ bool RemoveRepeatedChars(std::wstring& sentence) bool RemoveCyclicRepeats(std::wstring& sentence) { + if (sentence == L"") throw std::exception(); int junkLength = 0; wchar_t junk[2000] = {}; while (wcsstr(sentence.c_str() + junkLength, junk))