Huw Davies (@huw) commented about dlls/oleaut32/typelib.c:
+ bits.length = stream_length; + bits.current = 0; + + buf_size = *(const WORD *)table; + table += sizeof(WORD); + table_size = *(const DWORD *)table; + table += sizeof(DWORD); + + buf = SysAllocStringLen(NULL, buf_size); + buf[0] = 0; + + while ((p = lookup_code(table, table_size, &bits))) + { + static const WCHAR spaceW[] = { ' ',0 }; + if (buf[0]) lstrcatW(buf, spaceW); + MultiByteToWideChar(CP_ACP, 0, p, -1, buf + lstrlenW(buf), buf_size - lstrlenW(buf)); Could we tidy this up a bit please? If we first get the length of `buf` (and let's use `wcslen()`), there shouldn't be a need for further `lstr` or `wcs`-type functions.
-- https://gitlab.winehq.org/wine/wine/-/merge_requests/7334#note_94979