mirror of
https://github.com/reactos/reactos.git
synced 2024-12-28 18:15:11 +00:00
[WINSPOOL] Convert the returned Unicode string back to ANSI in GetDefaultPrinterA.
Thanks to Mark for the hint in CORE-14072!
This commit is contained in:
parent
de793ea5d6
commit
45b9b5c1ef
1 changed files with 3 additions and 0 deletions
|
@ -449,6 +449,9 @@ GetDefaultPrinterA(LPSTR pszBuffer, LPDWORD pcchBuffer)
|
|||
goto Cleanup;
|
||||
}
|
||||
|
||||
// We successfully got a string in pwszBuffer, so convert the Unicode string to ANSI.
|
||||
WideCharToMultiByte(CP_ACP, 0, pwszBuffer, -1, pszBuffer, *pcchBuffer, NULL, NULL);
|
||||
|
||||
dwErrorCode = ERROR_SUCCESS;
|
||||
|
||||
Cleanup:
|
||||
|
|
Loading…
Reference in a new issue