Author: hpoussin
Date: Tue Oct 2 18:38:14 2007
New Revision: 29354
URL:
http://svn.reactos.org/svn/reactos?rev=29354&view=rev
Log:
Simplify code.
Spotted by Pablo Menichini, pablo at menichini dot com dot ar
Modified:
trunk/reactos/base/setup/usetup/drivesup.c
Modified: trunk/reactos/base/setup/usetup/drivesup.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/setup/usetup/drivesup…
==============================================================================
--- trunk/reactos/base/setup/usetup/drivesup.c (original)
+++ trunk/reactos/base/setup/usetup/drivesup.c Tue Oct 2 18:38:14 2007
@@ -79,12 +79,13 @@
/* strip trailing directory */
Ptr = wcsrchr(SourceName.Buffer, L'\\');
if (Ptr)
+ {
RtlCreateUnicodeString(SourceRootDir, Ptr);
+ *Ptr = 0;
+ }
else
RtlCreateUnicodeString(SourceRootDir, L"");
- if (Ptr != NULL)
- *Ptr = 0;
RtlCreateUnicodeString(SourceRootPath,
SourceName.Buffer);
}