forgot header in last commit

bug report(1455) & patch by w3seek

svn path=/trunk/; revision=22178
This commit is contained in:
Johannes Anderwald
2006-06-02 14:08:22 +00:00
parent 42de812e46
commit 449a2042e7
+9
View File
@@ -74,6 +74,15 @@ VOID NTAPI W32kRaiseStatus(NTSTATUS Status);
#define ProbeForReadUlargeInteger(Ptr) ProbeForReadGenericType(Ptr, ULARGE_INTEGER, __emptyULargeInteger)
#define ProbeForReadUnicodeString(Ptr) ProbeForReadGenericType(Ptr, UNICODE_STRING, __emptyUnicodeString)
#define ProbeAndZeroHandle(Ptr) \
do { \
if ((ULONG_PTR)(Ptr) + sizeof(HANDLE) - 1 < (ULONG_PTR)(Ptr) || \
(ULONG_PTR)(Ptr) + sizeof(HANDLE) - 1 >= (ULONG_PTR)MmUserProbeAddress) { \
RtlRaiseStatus (STATUS_ACCESS_VIOLATION); \
} \
*(volatile HANDLE *)(Ptr) = NULL; \
} while (0)
/*
* Inlined Probing Macros
*/