Author: tkreuzer
Date: Mon Jun 15 18:49:31 2009
New Revision: 41418
URL:
http://svn.reactos.org/svn/reactos?rev=41418&view=rev
Log:
- Fix definition of RTL_HANDLE_TABLE_ENTRY
- Fix check in RtlFreeHandle and add a DPRINT
- Fixes the last ntdll:rtl winetest
Modified:
trunk/reactos/include/ndk/rtltypes.h
trunk/reactos/lib/rtl/handle.c
Modified: trunk/reactos/include/ndk/rtltypes.h
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/include/ndk/rtltypes.h?rev…
==============================================================================
--- trunk/reactos/include/ndk/rtltypes.h [iso-8859-1] (original)
+++ trunk/reactos/include/ndk/rtltypes.h [iso-8859-1] Mon Jun 15 18:49:31 2009
@@ -958,8 +958,11 @@
//
typedef struct _RTL_HANDLE_TABLE_ENTRY
{
- ULONG Flags;
- struct _RTL_HANDLE_TABLE_ENTRY *NextFree;
+ union
+ {
+ ULONG Flags;
+ struct _RTL_HANDLE_TABLE_ENTRY *NextFree;
+ };
} RTL_HANDLE_TABLE_ENTRY, *PRTL_HANDLE_TABLE_ENTRY;
typedef struct _RTL_HANDLE_TABLE
Modified: trunk/reactos/lib/rtl/handle.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/lib/rtl/handle.c?rev=41418…
==============================================================================
--- trunk/reactos/lib/rtl/handle.c [iso-8859-1] (original)
+++ trunk/reactos/lib/rtl/handle.c [iso-8859-1] Mon Jun 15 18:49:31 2009
@@ -127,8 +127,12 @@
{
#ifdef DBG
/* check if handle is valid */
- if (RtlIsValidHandle(HandleTable, Handle))
+ if (!RtlIsValidHandle(HandleTable, Handle))
+ {
+ DPRINT1("Invalid Handle! HandleTable=0x%p, Handle=0x%p,
Handle->Flags=0x%x\n",
+ HandleTable, Handle, Handle ? Handle->Flags : 0);
return FALSE;
+ }
#endif
/* clear handle */