comdlg32: Cast-qual warning fix.

This commit is contained in:
Andrew Talbot 2007-07-07 17:20:48 +01:00 committed by Alexandre Julliard
parent 382329c103
commit 234b0d8c1e
1 changed files with 5 additions and 3 deletions

View File

@ -76,10 +76,12 @@ static void CFn_CHOOSEFONT16to32W(const CHOOSEFONT16 *chf16, LPCHOOSEFONTW chf32
int len; int len;
if (chf16->Flags & CF_ENABLETEMPLATE) if (chf16->Flags & CF_ENABLETEMPLATE)
{ {
LPWSTR name32w;
len = MultiByteToWideChar( CP_ACP, 0, MapSL(chf16->lpTemplateName), -1, NULL, 0); len = MultiByteToWideChar( CP_ACP, 0, MapSL(chf16->lpTemplateName), -1, NULL, 0);
chf32w->lpTemplateName = HeapAlloc(GetProcessHeap(), 0, len * sizeof(WCHAR)); name32w = HeapAlloc(GetProcessHeap(), 0, len * sizeof(WCHAR));
MultiByteToWideChar( CP_ACP, 0, MapSL(chf16->lpTemplateName), MultiByteToWideChar( CP_ACP, 0, MapSL(chf16->lpTemplateName), -1, name32w, len);
-1, (LPWSTR)chf32w->lpTemplateName, len); chf32w->lpTemplateName = name32w;
} }
if (chf16->Flags & CF_USESTYLE) if (chf16->Flags & CF_USESTYLE)
{ {