Those are required to stop Fortnite from crashing during runtime
From: Infinite Loop teardown@inbox.ru
Those are required to stop Fortnite from crashing during runtime
Signed-off-by: Infinite Loop teardown@inbox.ru --- dlls/ntdll/ntdll.spec | 10 ++++----- dlls/ntdll/rtl.c | 52 ++++++++++++++++++++++++++++++++++++++++--- include/ddk/ntddk.h | 7 +++++- 3 files changed, 60 insertions(+), 9 deletions(-)
diff --git a/dlls/ntdll/ntdll.spec b/dlls/ntdll/ntdll.spec index 66995346e57..1d3f67a9d02 100644 --- a/dlls/ntdll/ntdll.spec +++ b/dlls/ntdll/ntdll.spec @@ -602,7 +602,7 @@ @ stdcall RtlDeleteCriticalSection(ptr) @ stdcall -arch=!i386 RtlDeleteGrowableFunctionTable(ptr) @ stub RtlDeleteElementGenericTable -@ stub RtlDeleteElementGenericTableAvl +@ stdcall RtlDeleteElementGenericTableAvl(ptr ptr) @ cdecl -arch=!i386 RtlDeleteFunctionTable(ptr) @ stub RtlDeleteNoSplay @ stub RtlDeleteOwnersRanges @@ -646,7 +646,7 @@ @ stdcall RtlEnterCriticalSection(ptr) @ stub RtlEnumProcessHeaps @ stub RtlEnumerateGenericTable -# @ stub RtlEnumerateGenericTableAvl +@ stdcall RtlEnumerateGenericTableAvl(ptr long) # @ stub RtlEnumerateGenericTableLikeADirectory @ stdcall RtlEnumerateGenericTableWithoutSplaying(ptr ptr) # @ stub RtlEnumerateGenericTableWithoutSplayingAvl @@ -725,7 +725,7 @@ @ stdcall RtlGetCurrentTransaction() @ stdcall RtlGetDaclSecurityDescriptor(ptr ptr ptr ptr) @ stdcall RtlGetElementGenericTable(ptr long) -# @ stub RtlGetElementGenericTableAvl +@ stdcall RtlGetElementGenericTableAvl(ptr long) @ stdcall RtlGetEnabledExtendedFeatures(int64) @ stdcall RtlGetExePath(wstr ptr) @ stdcall RtlGetExtendedContextLength(long ptr) @@ -876,7 +876,7 @@ # @ stub RtlLogStackBackTrace @ stdcall RtlLookupAtomInAtomTable(ptr wstr ptr) @ stdcall RtlLookupElementGenericTable(ptr ptr) -# @ stub RtlLookupElementGenericTableAvl +@ stdcall RtlLookupElementGenericTableAvl(ptr ptr) @ stdcall -arch=!i386 RtlLookupFunctionEntry(long ptr ptr) @ stdcall -arch=!i386 RtlLookupFunctionTable(long ptr ptr) @ stdcall RtlMakeSelfRelativeSD(ptr ptr ptr) @@ -898,7 +898,7 @@ @ stdcall RtlNtStatusToDosError(long) @ stdcall RtlNtStatusToDosErrorNoTeb(long) @ stdcall RtlNumberGenericTableElements(ptr) -# @ stub RtlNumberGenericTableElementsAvl +@ stdcall RtlNumberGenericTableElementsAvl(ptr) @ stdcall RtlNumberOfClearBits(ptr) @ stdcall RtlNumberOfSetBits(ptr) @ stdcall RtlOemStringToUnicodeSize(ptr) diff --git a/dlls/ntdll/rtl.c b/dlls/ntdll/rtl.c index 3d482ec2f92..ec68e65736a 100644 --- a/dlls/ntdll/rtl.c +++ b/dlls/ntdll/rtl.c @@ -2164,15 +2164,61 @@ BOOLEAN WINAPI RtlIsProcessorFeaturePresent( UINT feature ) void WINAPI RtlInitializeGenericTableAvl(PRTL_AVL_TABLE table, PRTL_AVL_COMPARE_ROUTINE compare, PRTL_AVL_ALLOCATE_ROUTINE allocate, PRTL_AVL_FREE_ROUTINE free, void *context) { - FIXME("%p %p %p %p %p: stub\n", table, compare, allocate, free, context); + FIXME("(%p, %p, %p, %p, %p): stub\n", table, compare, allocate, free, context); }
/*********************************************************************** * RtlInsertElementGenericTableAvl (NTDLL.@) */ -void WINAPI RtlInsertElementGenericTableAvl(PRTL_AVL_TABLE table, void *buffer, ULONG size, BOOL *element) +void * WINAPI RtlInsertElementGenericTableAvl(PRTL_AVL_TABLE table, void *buffer, ULONG size, BOOLEAN *element) { - FIXME("%p %p %lu %p: stub\n", table, buffer, size, element); + FIXME("(%p, %p, %lu, %p): stub\n", table, buffer, size, element); + return NULL; +} + +/*********************************************************************** + * RtlGetElementGenericTableAvl (NTDLL.@) + */ +void * WINAPI RtlGetElementGenericTableAvl(PRTL_AVL_TABLE table, ULONG index) +{ + FIXME("(%p, %u): stub\n", table, index); + return NULL; +} + +/*********************************************************************** + * RtlLookupElementGenericTableAvl (NTDLL.@) + */ +void * WINAPI RtlLookupElementGenericTableAvl(PRTL_AVL_TABLE table, void *buffer) +{ + FIXME("(%p, %p): stub\n", table, buffer); + return NULL; +} + +/*********************************************************************** + * RtlDeleteElementGenericTableAvl (NTDLL.@) + */ +BOOLEAN WINAPI RtlDeleteElementGenericTableAvl(PRTL_AVL_TABLE table, void *buffer) +{ + FIXME("(%p, %p): stub\n", table, buffer); + return FALSE; +} + +/*********************************************************************** + * RtlEnumerateGenericTableAvl (NTDLL.@) + */ +void * WINAPI RtlEnumerateGenericTableAvl(PRTL_AVL_TABLE table, BOOLEAN restart) +{ + FIXME("(%p, %s): stub\n", table, restart ? "TRUE" : "FALSE"); + return NULL; +} + +/*********************************************************************** + * RtlNumberGenericTableElementsAvl (NTDLL.@) + */ +ULONG WINAPI RtlNumberGenericTableElementsAvl(PRTL_AVL_TABLE table) +{ + FIXME("(%p): stub\n", table); + return 0UL; }
/********************************************************************* diff --git a/include/ddk/ntddk.h b/include/ddk/ntddk.h index 471c27c27ba..a245312ced6 100644 --- a/include/ddk/ntddk.h +++ b/include/ddk/ntddk.h @@ -272,7 +272,12 @@ BOOLEAN WINAPI RtlEqualString(const STRING*,const STRING*,BOOLEAN); void * WINAPI RtlGetElementGenericTable(PRTL_GENERIC_TABLE,ULONG); void WINAPI RtlInitializeGenericTable(PRTL_GENERIC_TABLE,PRTL_GENERIC_COMPARE_ROUTINE,PRTL_GENERIC_ALLOCATE_ROUTINE,PRTL_GENERIC_FREE_ROUTINE,void *); void WINAPI RtlInitializeGenericTableAvl(PRTL_AVL_TABLE,PRTL_AVL_COMPARE_ROUTINE,PRTL_AVL_ALLOCATE_ROUTINE, PRTL_AVL_FREE_ROUTINE,void *); -void WINAPI RtlInsertElementGenericTableAvl(PRTL_AVL_TABLE,void *,ULONG,BOOL*); +void * WINAPI RtlInsertElementGenericTableAvl(PRTL_AVL_TABLE,void *,ULONG,BOOLEAN*); +void * WINAPI RtlGetElementGenericTableAvl(PRTL_AVL_TABLE,ULONG); +void * WINAPI RtlLookupElementGenericTableAvl(PRTL_AVL_TABLE,void *); +BOOLEAN WINAPI RtlDeleteElementGenericTableAvl(PRTL_AVL_TABLE,void *); +void * WINAPI RtlEnumerateGenericTableAvl(PRTL_AVL_TABLE,BOOLEAN); +ULONG WINAPI RtlNumberGenericTableElementsAvl(PRTL_AVL_TABLE); void * WINAPI RtlLookupElementGenericTable(PRTL_GENERIC_TABLE,void *); void WINAPI RtlMapGenericMask(ACCESS_MASK*,const GENERIC_MAPPING*); ULONG WINAPI RtlNumberGenericTableElements(PRTL_GENERIC_TABLE);