mirror of
https://github.com/reactos/reactos.git
synced 2025-08-05 15:23:03 +00:00
SetupDiGetDeviceInstanceId returns size in characters not in bytes
svn path=/trunk/; revision=30606
This commit is contained in:
parent
2b14de3b3c
commit
0fdacaa71e
2 changed files with 2 additions and 2 deletions
|
@ -150,7 +150,7 @@ UpdateDriverForPlugAndPlayDevicesW(
|
||||||
TRACE("SetupDiGetDeviceInstanceIdW() failed with error 0x%x\n", GetLastError());
|
TRACE("SetupDiGetDeviceInstanceIdW() failed with error 0x%x\n", GetLastError());
|
||||||
goto cleanup;
|
goto cleanup;
|
||||||
}
|
}
|
||||||
else if ((Buffer = HeapAlloc(GetProcessHeap(), 0, BufferSize)) == NULL)
|
else if ((Buffer = HeapAlloc(GetProcessHeap(), 0, BufferSize * sizeof(WCHAR))) == NULL)
|
||||||
{
|
{
|
||||||
TRACE("HeapAlloc() failed\n", GetLastError());
|
TRACE("HeapAlloc() failed\n", GetLastError());
|
||||||
SetLastError(ERROR_NOT_ENOUGH_MEMORY);
|
SetLastError(ERROR_NOT_ENOUGH_MEMORY);
|
||||||
|
|
|
@ -236,7 +236,7 @@ PopulateCustomPathCombo(
|
||||||
{
|
{
|
||||||
HKEY hKey = NULL;
|
HKEY hKey = NULL;
|
||||||
DWORD dwRegType;
|
DWORD dwRegType;
|
||||||
DWORD dwPathLength;
|
DWORD dwPathLength = 0;
|
||||||
LPWSTR Buffer = NULL;
|
LPWSTR Buffer = NULL;
|
||||||
LPCWSTR Path;
|
LPCWSTR Path;
|
||||||
LONG rc;
|
LONG rc;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue