linux PIString fix

This commit is contained in:
2022-04-25 23:58:38 +03:00
parent 0cf7fb9f25
commit 0aaa5ba890

View File

@@ -246,7 +246,7 @@ void PIString::appendFromChars(const char * c, int s, const char * codepage) {
size_t len = mbsrtowcs(NULL, pc, 0, &state);
wchar_t wstr[len+1];
mbsrtowcs(&wstr[0], pc, len+1, &state);
if (s > 0) free(c_);
if (c_) free(c_);
enlarge(len);
for (size_t i=0; i<len; ++i) (*this)[old_sz+i] = wstr[i];
// //qDebug() << "FromChars done" << size();