Author: dchapyshev
Date: Tue Aug 30 17:36:01 2016
New Revision: 72511
URL:
http://svn.reactos.org/svn/reactos?rev=72511&view=rev
Log:
[KERNEL32]
- Initialization of a string before obtaining information
* Fixes 2 tests for kernel32_apitest GetComputerNameEx (all tests passed now)
Modified:
trunk/reactos/dll/win32/kernel32/client/compname.c
Modified: trunk/reactos/dll/win32/kernel32/client/compname.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/kernel32/client/…
==============================================================================
--- trunk/reactos/dll/win32/kernel32/client/compname.c [iso-8859-1] (original)
+++ trunk/reactos/dll/win32/kernel32/client/compname.c [iso-8859-1] Tue Aug 30 17:36:01
2016
@@ -50,6 +50,9 @@
ULONG ReturnSize;
NTSTATUS Status;
+ if (lpBuffer != NULL && *nSize > 0)
+ lpBuffer[0] = 0;
+
RtlInitUnicodeString(&KeyName, RegistryKey);
InitializeObjectAttributes(&ObjectAttributes,
&KeyName,