J
Jordan Abel
Is there a function to find the length, in wide characters, of a
multibyte string?
multibyte string?
Jordan Abel said:Is there a function to find the length, in wide characters, of a
multibyte string?
<OT>
If you have the POSIX version of mbstowcs, you can pass it a NULL
first argument to get this number.
</OT>
If you limit yourself to Standard C, I think you have to actually
perform the conversion, and then find out with wcslen().
Jordan Abel said:Given that this came up when i was trying to answer someone's question
in c.u.p, this is relevant, thanks.
The reason for this was to be able to perform the conversion into memory
that is from malloc while calling malloc only once. in order to make a
wide copy of argv to pass to a "wmain"
Want to reply to this thread or ask your own question?
You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.