[ros-diffs] [cwittich] 26395: use the correct index in Module32Next

cwittich at svn.reactos.org cwittich at svn.reactos.org
Wed Apr 18 15:39:27 CEST 2007


Author: cwittich
Date: Wed Apr 18 17:39:26 2007
New Revision: 26395

URL: http://svn.reactos.org/svn/reactos?rev=26395&view=rev
Log:
use the correct index in Module32Next

Modified:
    trunk/reactos/dll/win32/kernel32/misc/toolhelp.c

Modified: trunk/reactos/dll/win32/kernel32/misc/toolhelp.c
URL: http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/kernel32/misc/toolhelp.c?rev=26395&r1=26394&r2=26395&view=diff
==============================================================================
--- trunk/reactos/dll/win32/kernel32/misc/toolhelp.c (original)
+++ trunk/reactos/dll/win32/kernel32/misc/toolhelp.c Wed Apr 18 17:39:26 2007
@@ -760,11 +760,11 @@
   {
     BOOL Ret;
 
-    if(Snapshot->ModuleListCount > 0 &&
-       Snapshot->ModuleListIndex < Snapshot->ModuleListCount)
+    if((Snapshot->ModuleListCount > 0) &&
+       (Snapshot->ModuleListIndex < Snapshot->ModuleListCount))
     {
       LPMODULEENTRY32W Entries = (LPMODULEENTRY32W)OffsetToPtr(Snapshot, Snapshot->ModuleListOffset);
-      RtlCopyMemory(lpme, &Entries[Snapshot->ProcessListIndex++], sizeof(MODULEENTRY32W));
+      RtlCopyMemory(lpme, &Entries[Snapshot->ModuleListIndex++], sizeof(MODULEENTRY32W));
       Ret = TRUE;
     }
     else




More information about the Ros-diffs mailing list