Handle CreateMetaFileW(NULL) correctly.
This commit is contained in:
parent
f7f7bd0cfe
commit
69ac76d050
|
@ -263,6 +263,8 @@ HDC WINAPI CreateMetaFileW(LPCWSTR filename)
|
|||
DWORD len;
|
||||
HDC hReturnDC;
|
||||
|
||||
if (!filename) return CreateMetaFileA(NULL);
|
||||
|
||||
len = WideCharToMultiByte( CP_ACP, 0, filename, -1, NULL, 0, NULL, NULL );
|
||||
filenameA = HeapAlloc( GetProcessHeap(), 0, len );
|
||||
WideCharToMultiByte( CP_ACP, 0, filename, -1, filenameA, len, NULL, NULL );
|
||||
|
|
Loading…
Reference in New Issue