Author: tkreuzer
Date: Wed Jul 20 16:29:38 2011
New Revision: 52741
URL:
http://svn.reactos.org/svn/reactos?rev=52741&view=rev
Log:
[NTOSKRNL]
Patch by Thomas Faber
ExAcquireSharedStarveExclusive and ExAcquireSharedWaitForExclusive should
return FALSE when they cannot immediately acquire the resource, and the Wait parameter is
false. They return TRUE instead, leading the caller to believe it acquired the resource,
which will result in a bugcheck when it tries to release it.
See issue #6375 for more details.
Modified:
trunk/reactos/ntoskrnl/ex/resource.c
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] Wed Jul 20 16:29:38 2011
@@ -1159,7 +1159,7 @@
{
/* Release the lock and return */
ExReleaseResourceLock(Resource, &LockHandle);
- return TRUE;
+ return FALSE;
}
/* Check if we have a shared waiters semaphore */
@@ -1276,7 +1276,7 @@
{
/* So bail out if we're not allowed */
ExReleaseResourceLock(Resource, &LockHandle);
- return TRUE;
+ return FALSE;
}
/* Check if we have a shared waiters semaphore */
@@ -1359,7 +1359,7 @@
{
/* So bail out if we're not allowed */
ExReleaseResourceLock(Resource, &LockHandle);
- return TRUE;
+ return FALSE;
}
/* Check if we have a shared waiters semaphore */