Angus Leeming <[EMAIL PROTECTED]> writes:
| In fact, when I look at your code, why don't you make iconv_convert a
| template and return a vector of the correct type directly. All that's
| needed is a change to the last couple of lines of iconv_convert where
| you fill outvec:
|
| int const bytes = 1000 - outbytesleft;
| std::size_t length_outvec = bytes * sizeof(char) / sizeof(T);
| ASSERT(length_outvec * sizeof(T) / sizeof(char) == bytes);
|
| std::vector<T> outvec(length_outvec);
| std::memcpy(&outvec[0], out, bytes);
| return outvec;
|
| I think that the only assumption is that "ucs-4-internal" is a valid
| flag to pass to iconv itself and that iconv will then do the right
| thing when filling the char* buffer.
|
| What do I miss?
converting to utf-8.
--
Lgb