mirror of
https://github.com/reactos/reactos.git
synced 2024-12-28 10:04:49 +00:00
[APPHELP] Implement ShimDumpCache and ShimFlushCache
These functions simply call into the Base* functions, having a prototype that is compatible with rundll32 CORE-11301
This commit is contained in:
parent
f2f54a052e
commit
5c05a29d3d
4 changed files with 50 additions and 8 deletions
|
@ -292,3 +292,38 @@ BOOL WINAPI SdbUnregisterDatabase(_In_ GUID *pguidDB)
|
|||
return FALSE;
|
||||
}
|
||||
|
||||
|
||||
/* kernel32.dll */
|
||||
BOOL WINAPI BaseDumpAppcompatCache(VOID);
|
||||
BOOL WINAPI BaseFlushAppcompatCache(VOID);
|
||||
|
||||
|
||||
/**
|
||||
* @name ShimDumpCache
|
||||
* Dump contents of the shim cache.
|
||||
*
|
||||
* @param hwnd Unused, pass 0
|
||||
* @param hInstance Unused, pass 0
|
||||
* @param lpszCmdLine Unused, pass 0
|
||||
* @param nCmdShow Unused, pass 0
|
||||
* @return
|
||||
*/
|
||||
BOOL WINAPI ShimDumpCache(HWND hwnd, HINSTANCE hInstance, LPCSTR lpszCmdLine, int nCmdShow)
|
||||
{
|
||||
return BaseDumpAppcompatCache();
|
||||
}
|
||||
|
||||
/**
|
||||
* @name ShimFlushCache
|
||||
* Flush the shim cache. Call this after installing a new shim database
|
||||
*
|
||||
* @param hwnd Unused, pass 0
|
||||
* @param hInstance Unused, pass 0
|
||||
* @param lpszCmdLine Unused, pass 0
|
||||
* @param nCmdShow Unused, pass 0
|
||||
* @return
|
||||
*/
|
||||
BOOL WINAPI ShimFlushCache(HWND hwnd, HINSTANCE hInstance, LPCSTR lpszCmdLine, int nCmdShow)
|
||||
{
|
||||
return BaseFlushAppcompatCache();
|
||||
}
|
||||
|
|
|
@ -173,7 +173,7 @@
|
|||
@ stub SE_LdrEntryRemoved
|
||||
@ stub SetPermLayers
|
||||
@ cdecl ShimDbgPrint(long str str)
|
||||
@ stub ShimDumpCache
|
||||
@ stub ShimFlushCache
|
||||
@ stdcall ShimDumpCache(ptr ptr wstr long)
|
||||
@ stdcall ShimFlushCache(ptr ptr wstr long)
|
||||
@ stdcall SetPermLayerState(wstr wstr long long long)
|
||||
@ stdcall SdbRegisterDatabaseEx(wstr long ptr)
|
||||
|
|
|
@ -309,23 +309,29 @@ BasepCheckBadapp(IN HANDLE FileHandle,
|
|||
}
|
||||
|
||||
/*
|
||||
* @unimplemented
|
||||
* @implemented
|
||||
*/
|
||||
VOID
|
||||
BOOL
|
||||
WINAPI
|
||||
BaseDumpAppcompatCache(VOID)
|
||||
{
|
||||
STUB;
|
||||
NTSTATUS Status;
|
||||
|
||||
Status = NtApphelpCacheControl(ApphelpCacheServiceDump, NULL);
|
||||
return NT_SUCCESS(Status);
|
||||
}
|
||||
|
||||
/*
|
||||
* @unimplemented
|
||||
* @implemented
|
||||
*/
|
||||
VOID
|
||||
BOOL
|
||||
WINAPI
|
||||
BaseFlushAppcompatCache(VOID)
|
||||
{
|
||||
STUB;
|
||||
NTSTATUS Status;
|
||||
|
||||
Status = NtApphelpCacheControl(ApphelpCacheServiceFlush, NULL);
|
||||
return NT_SUCCESS(Status);
|
||||
}
|
||||
|
||||
/*
|
||||
|
|
|
@ -764,6 +764,7 @@ NtApphelpCacheControl(
|
|||
}
|
||||
break;
|
||||
case ApphelpCacheServiceFlush:
|
||||
/* FIXME: Check for admin or system here. */
|
||||
Status = ApphelpCacheFlush();
|
||||
break;
|
||||
case ApphelpCacheServiceDump:
|
||||
|
|
Loading…
Reference in a new issue