Author: ekohl
Date: Thu Dec 10 15:43:06 2015
New Revision: 70321
URL:
http://svn.reactos.org/svn/reactos?rev=70321&view=rev
Log:
[USETUP]
Check RtlCreateUnicodeString in SetupCreateSingleDirectory.
Patch by Victor Martinez.
CORE-10647 #resolve #comment Thanks a lot!
Modified:
trunk/reactos/base/setup/usetup/filesup.c
Modified: trunk/reactos/base/setup/usetup/filesup.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/setup/usetup/filesup.…
==============================================================================
--- trunk/reactos/base/setup/usetup/filesup.c [iso-8859-1] (original)
+++ trunk/reactos/base/setup/usetup/filesup.c [iso-8859-1] Thu Dec 10 15:43:06 2015
@@ -48,8 +48,9 @@
HANDLE DirectoryHandle;
NTSTATUS Status;
- RtlCreateUnicodeString(&PathName,
- DirectoryName);
+ if(!RtlCreateUnicodeString(&PathName, DirectoryName))
+ return STATUS_NO_MEMORY;
+
if (PathName.Length > sizeof(WCHAR) &&
PathName.Buffer[PathName.Length / sizeof(WCHAR) - 2] == L'\\' &&
PathName.Buffer[PathName.Length / sizeof(WCHAR) - 1] == L'.')