kernel32: Change LCMapStringW to LCMapStringEx and call it from LCMapStringW (try 2)

Alexandre Julliard julliard at winehq.org
Tue Jun 26 12:39:53 CDT 2012


André Hentschel <nerv at dawncrow.de> writes:

> @@ -2625,6 +2641,28 @@ INT WINAPI LCMapStringW(LCID lcid, DWORD flags, LPCWSTR src, INT srclen,
>  }
>  
>  /*************************************************************************
> + *           LCMapStringW    (KERNEL32.@)
> + *
> + * See LCMapStringA.
> + */
> +INT WINAPI LCMapStringW(LCID lcid, DWORD flags, LPCWSTR src, INT srclen,
> +                        LPWSTR dst, INT dstlen)
> +{
> +    WCHAR locale[LOCALE_NAME_MAX_LENGTH];
> +
> +    TRACE("(0x%04x,0x%08x,%s,%d,%p,%d)\n",
> +          lcid, flags, debugstr_wn(src, srclen), srclen, dst, dstlen);
> +
> +    if (!LCIDToLocaleName(lcid, locale, LOCALE_NAME_MAX_LENGTH, 0))
> +    {
> +        SetLastError(ERROR_INVALID_PARAMETER);
> +        return 0;
> +    }

I don't think it makes sense to do name conversion for a parameter that
isn't used. If we use it someday it will most likely be to look up a
conversion table directly from the lcid.

-- 
Alexandre Julliard
julliard at winehq.org



More information about the wine-devel mailing list