linux PIString fix
This commit is contained in:
@@ -242,9 +242,9 @@ void PIString::appendFromChars(const char * c, int s, const char * codepage) {
|
|||||||
} else {
|
} else {
|
||||||
pc = c;
|
pc = c;
|
||||||
}
|
}
|
||||||
size_t len = mbsrtowcs(NULL, &pc, 0, &state);
|
size_t len = mbsrtowcs(NULL, (const char**)&pc, 0, &state);
|
||||||
wchar_t wstr[len+1];
|
wchar_t wstr[len+1];
|
||||||
mbsrtowcs(&wstr[0], &pc, len+1, &state);
|
mbsrtowcs(&wstr[0], (const char**)&pc, len+1, &state);
|
||||||
enlarge(len);
|
enlarge(len);
|
||||||
for (size_t i=0; i<len; ++i) (*this)[old_sz+i] = wstr[i];
|
for (size_t i=0; i<len; ++i) (*this)[old_sz+i] = wstr[i];
|
||||||
// //qDebug() << "FromChars done" << size();
|
// //qDebug() << "FromChars done" << size();
|
||||||
|
|||||||
Reference in New Issue
Block a user