dbghelp: A few fixes related to Unicode translation.

This commit is contained in:
Eric Pouech 2007-02-21 21:56:01 +01:00 committed by Alexandre Julliard
parent 1690cf1815
commit c0fa60f547
1 changed files with 2 additions and 3 deletions

View File

@ -191,13 +191,12 @@ BOOL WINAPI SymGetSearchPathW(HANDLE hProcess, LPWSTR szSearchPath,
BOOL WINAPI SymGetSearchPath(HANDLE hProcess, LPSTR szSearchPath,
DWORD SearchPathLength)
{
WCHAR* buffer = HeapAlloc(GetProcessHeap(), 0, SearchPathLength);
WCHAR* buffer = HeapAlloc(GetProcessHeap(), 0, SearchPathLength * sizeof(WCHAR));
BOOL ret = FALSE;
if (buffer)
{
ret = SymGetSearchPathW(hProcess, buffer,
SearchPathLength * sizeof(WCHAR));
ret = SymGetSearchPathW(hProcess, buffer, SearchPathLength);
if (ret)
WideCharToMultiByte(CP_ACP, 0, buffer, SearchPathLength,
szSearchPath, SearchPathLength, NULL, NULL);