diff --git a/src/wrapasvst3.cpp b/src/wrapasvst3.cpp index ac79e676..3798ae9a 100644 --- a/src/wrapasvst3.cpp +++ b/src/wrapasvst3.cpp @@ -49,7 +49,7 @@ void utf8_to_utf16l(const char* utf8string, uint16_t* target, size_t targetsize) auto src = reinterpret_cast(utf8string); size_t pos = 0; - while (src[pos] && (targetpos < (targetsize - 1))) + while (src[pos] && (targetpos < (targetsize - 2))) { auto byte = src[pos];