Skip to content

Commit 684072f

Browse files
committed
[NDK] Minor header improvements
- Remove some duplicated prototypes - Fix a few mismatching annotations
1 parent 9563c07 commit 684072f

File tree

2 files changed

+20
-48
lines changed

2 files changed

+20
-48
lines changed

sdk/include/ndk/rtlfuncs.h

Lines changed: 19 additions & 48 deletions
Original file line numberDiff line numberDiff line change
@@ -851,7 +851,7 @@ RtlVirtualUnwind(
851851
_In_ ULONG64 ControlPc,
852852
_In_ PRUNTIME_FUNCTION FunctionEntry,
853853
_Inout_ PCONTEXT Context,
854-
_Outptr_ PVOID* HandlerData,
854+
_Out_ PVOID* HandlerData,
855855
_Out_ PULONG64 EstablisherFrame,
856856
_Inout_opt_ PKNONVOLATILE_CONTEXT_POINTERS ContextPointers
857857
);
@@ -1868,9 +1868,24 @@ RtlCharToInteger(
18681868
//
18691869
#ifdef NTOS_MODE_USER
18701870

1871-
unsigned short __cdecl _byteswap_ushort(unsigned short);
1872-
unsigned long __cdecl _byteswap_ulong (unsigned long);
1873-
unsigned __int64 __cdecl _byteswap_uint64(unsigned __int64);
1871+
_Check_return_
1872+
unsigned short
1873+
__cdecl
1874+
_byteswap_ushort(
1875+
_In_ unsigned short _Short);
1876+
1877+
_Check_return_
1878+
unsigned long
1879+
__cdecl
1880+
_byteswap_ulong(
1881+
_In_ unsigned long _Long);
1882+
1883+
_Check_return_
1884+
unsigned __int64
1885+
__cdecl
1886+
_byteswap_uint64(
1887+
_In_ unsigned __int64 _Int64);
1888+
18741889
#ifdef _MSC_VER
18751890
#pragma intrinsic(_byteswap_ushort)
18761891
#pragma intrinsic(_byteswap_ulong)
@@ -3838,50 +3853,6 @@ DbgCommandString(
38383853
_In_ PCCH Command
38393854
);
38403855

3841-
//
3842-
// Generic Table Functions
3843-
//
3844-
#if defined(NTOS_MODE_USER) || defined(_NTIFS_)
3845-
NTSYSAPI
3846-
PVOID
3847-
NTAPI
3848-
RtlInsertElementGenericTable(
3849-
_In_ PRTL_GENERIC_TABLE Table,
3850-
_In_reads_bytes_(BufferSize) PVOID Buffer,
3851-
_In_ CLONG BufferSize,
3852-
_Out_opt_ PBOOLEAN NewElement
3853-
);
3854-
3855-
NTSYSAPI
3856-
PVOID
3857-
NTAPI
3858-
RtlInsertElementGenericTableFull(
3859-
_In_ PRTL_GENERIC_TABLE Table,
3860-
_In_reads_bytes_(BufferSize) PVOID Buffer,
3861-
_In_ CLONG BufferSize,
3862-
_Out_opt_ PBOOLEAN NewElement,
3863-
_In_ PVOID NodeOrParent,
3864-
_In_ TABLE_SEARCH_RESULT SearchResult
3865-
);
3866-
3867-
NTSYSAPI
3868-
BOOLEAN
3869-
NTAPI
3870-
RtlIsGenericTableEmpty(
3871-
_In_ PRTL_GENERIC_TABLE Table
3872-
);
3873-
3874-
NTSYSAPI
3875-
PVOID
3876-
NTAPI
3877-
RtlLookupElementGenericTableFull(
3878-
_In_ PRTL_GENERIC_TABLE Table,
3879-
_In_ PVOID Buffer,
3880-
_Out_ PVOID *NodeOrParent,
3881-
_Out_ TABLE_SEARCH_RESULT *SearchResult
3882-
);
3883-
#endif
3884-
38853856
//
38863857
// Handle Table Functions
38873858
//

sdk/include/ndk/sefuncs.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -443,6 +443,7 @@ ZwOpenProcessToken(
443443
_In_ ACCESS_MASK DesiredAccess,
444444
_Out_ PHANDLE TokenHandle);
445445

446+
_IRQL_requires_max_(PASSIVE_LEVEL)
446447
NTSYSAPI
447448
NTSTATUS
448449
NTAPI

0 commit comments

Comments
 (0)