mirror of
https://github.com/reactos/reactos.git
synced 2024-07-01 02:10:07 +00:00
[KERNEL32] GetComputerNameExW: Fix crash in kernel32_winetest environ test
This commit is contained in:
parent
88a69b446b
commit
38160b207d
|
@ -236,7 +236,8 @@ GetComputerNameExW(COMPUTER_NAME_FORMAT NameType,
|
|||
L"ComputerName",
|
||||
lpBuffer,
|
||||
nSize);
|
||||
if (ret == FALSE)
|
||||
if ((ret == FALSE) &&
|
||||
(GetLastError() != ERROR_MORE_DATA))
|
||||
{
|
||||
ret = GetComputerNameFromRegistry(L"\\Registry\\Machine\\System\\CurrentControlSet"
|
||||
L"\\Control\\ComputerName\\ComputerName",
|
||||
|
|
Loading…
Reference in a new issue