Author: rharabien
Date: Sat Jun 25 10:26:59 2011
New Revision: 52450
URL:
http://svn.reactos.org/svn/reactos?rev=52450&view=rev
Log:
[NTOSKRNL]
- Fix some MSVC warnings
- Fix typo in IoReleaseRemoveLockEx
Modified:
trunk/reactos/ntoskrnl/cc/copy.c
trunk/reactos/ntoskrnl/ex/resource.c
trunk/reactos/ntoskrnl/ex/sysinfo.c
trunk/reactos/ntoskrnl/fstub/translate.c
trunk/reactos/ntoskrnl/io/iomgr/remlock.c
trunk/reactos/ntoskrnl/io/iomgr/util.c
Modified: trunk/reactos/ntoskrnl/cc/copy.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/ntoskrnl/cc/copy.c?rev=524…
==============================================================================
--- trunk/reactos/ntoskrnl/cc/copy.c [iso-8859-1] (original)
+++ trunk/reactos/ntoskrnl/cc/copy.c [iso-8859-1] Sat Jun 25 10:26:59 2011
@@ -255,7 +255,7 @@
// MmGlobalPageDirectory and the real system PDE directory. What a mess...
//
{
- int i = 0;
+ ULONG i = 0;
do
{
MmGetPfnForProcess(NULL, (PVOID)((ULONG_PTR)CacheSeg->BaseAddress + (i
<< PAGE_SHIFT)));
Modified: trunk/reactos/ntoskrnl/ex/resource.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/ntoskrnl/ex/resource.c?rev…
==============================================================================
--- trunk/reactos/ntoskrnl/ex/resource.c [iso-8859-1] (original)
+++ trunk/reactos/ntoskrnl/ex/resource.c [iso-8859-1] Sat Jun 25 10:26:59 2011
@@ -13,8 +13,8 @@
#include <debug.h>
/* Macros for reading resource flags */
-#define IsExclusiveWaiting(r) (r->NumberOfExclusiveWaiters)
-#define IsSharedWaiting(r) (r->NumberOfSharedWaiters)
+#define IsExclusiveWaiting(r) (r->NumberOfExclusiveWaiters > 0)
+#define IsSharedWaiting(r) (r->NumberOfSharedWaiters > 0)
#define IsOwnedExclusive(r) (r->Flag & ResourceOwnedExclusive)
#define IsBoostAllowed(r) (!(r->Flag & ResourceHasDisabledPriorityBoost))
Modified: trunk/reactos/ntoskrnl/ex/sysinfo.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/ntoskrnl/ex/sysinfo.c?rev=…
==============================================================================
--- trunk/reactos/ntoskrnl/ex/sysinfo.c [iso-8859-1] (original)
+++ trunk/reactos/ntoskrnl/ex/sysinfo.c [iso-8859-1] Sat Jun 25 10:26:59 2011
@@ -1465,8 +1465,9 @@
PSYSTEM_EXCEPTION_INFORMATION ExceptionInformation =
(PSYSTEM_EXCEPTION_INFORMATION)Buffer;
PKPRCB Prcb;
- ULONG i, AlignmentFixupCount = 0, ExceptionDispatchCount = 0;
+ ULONG AlignmentFixupCount = 0, ExceptionDispatchCount = 0;
ULONG FloatingEmulationCount = 0, ByteWordEmulationCount = 0;
+ CHAR i;
/* Check size of a buffer, it must match our expectations */
if (sizeof(SYSTEM_EXCEPTION_INFORMATION) != Size)
@@ -1523,8 +1524,9 @@
{
PSYSTEM_CONTEXT_SWITCH_INFORMATION ContextSwitchInformation =
(PSYSTEM_CONTEXT_SWITCH_INFORMATION)Buffer;
- ULONG ContextSwitches, i;
+ ULONG ContextSwitches;
PKPRCB Prcb;
+ CHAR i;
/* Check size of a buffer, it must match our expectations */
if (sizeof(SYSTEM_CONTEXT_SWITCH_INFORMATION) != Size)
Modified: trunk/reactos/ntoskrnl/fstub/translate.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/ntoskrnl/fstub/translate.c…
==============================================================================
--- trunk/reactos/ntoskrnl/fstub/translate.c [iso-8859-1] (original)
+++ trunk/reactos/ntoskrnl/fstub/translate.c [iso-8859-1] Sat Jun 25 10:26:59 2011
@@ -40,10 +40,9 @@
IN PDEVICE_OBJECT PhysicalDeviceObject,
OUT PCM_PARTIAL_RESOURCE_DESCRIPTOR Target)
{
- INT k;
KIRQL Irql;
KAFFINITY Affinity;
- ULONG MinimumVector, Vector;
+ ULONG MinimumVector, Vector, k;
PIO_RESOURCE_DESCRIPTOR Alternative;
NTSTATUS Status = STATUS_UNSUCCESSFUL;
PAGED_CODE();
Modified: trunk/reactos/ntoskrnl/io/iomgr/remlock.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/ntoskrnl/io/iomgr/remlock.…
==============================================================================
--- trunk/reactos/ntoskrnl/io/iomgr/remlock.c [iso-8859-1] (original)
+++ trunk/reactos/ntoskrnl/io/iomgr/remlock.c [iso-8859-1] Sat Jun 25 10:26:59 2011
@@ -205,7 +205,7 @@
/* Check if it was because we were low in memory
* If yes, then ignore, that's normal
*/
- if (InterlockedDecrement(&(Lock->Dbg.LowMemoryCount) < 0))
+ if (InterlockedDecrement(&(Lock->Dbg.LowMemoryCount)) < 0)
{
/* Otherwise signal the issue, it shouldn't happen */
InterlockedIncrement(&(Lock->Dbg.LowMemoryCount));
Modified: trunk/reactos/ntoskrnl/io/iomgr/util.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/ntoskrnl/io/iomgr/util.c?r…
==============================================================================
--- trunk/reactos/ntoskrnl/io/iomgr/util.c [iso-8859-1] (original)
+++ trunk/reactos/ntoskrnl/io/iomgr/util.c [iso-8859-1] Sat Jun 25 10:26:59 2011
@@ -166,8 +166,7 @@
OUT PULONG ErrorOffset)
{
PFILE_FULL_EA_INFORMATION EaBufferEnd;
- ULONG NextEaBufferOffset;
- LONG IntEaLength;
+ ULONG NextEaBufferOffset, IntEaLength;
PAGED_CODE();