2 * Centralised Unicode-related helper functions, separate from misc.c
3 * so that they can be omitted from tools that aren't including
10 wchar_t *dup_mb_to_wc_c(int codepage, int flags, const char *string, int len)
13 for (mult = 1 ;; mult++) {
14 wchar_t *ret = snewn(mult*len + 2, wchar_t);
16 outlen = mb_to_wc(codepage, flags, string, len, ret, mult*len + 1);
17 if (outlen < mult*len+1) {
25 wchar_t *dup_mb_to_wc(int codepage, int flags, const char *string)
27 return dup_mb_to_wc_c(codepage, flags, string, strlen(string));