mirror of
https://github.com/reactos/reactos.git
synced 2024-12-31 19:42:51 +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;
|
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 SE_LdrEntryRemoved
|
||||||
@ stub SetPermLayers
|
@ stub SetPermLayers
|
||||||
@ cdecl ShimDbgPrint(long str str)
|
@ cdecl ShimDbgPrint(long str str)
|
||||||
@ stub ShimDumpCache
|
@ stdcall ShimDumpCache(ptr ptr wstr long)
|
||||||
@ stub ShimFlushCache
|
@ stdcall ShimFlushCache(ptr ptr wstr long)
|
||||||
@ stdcall SetPermLayerState(wstr wstr long long long)
|
@ stdcall SetPermLayerState(wstr wstr long long long)
|
||||||
@ stdcall SdbRegisterDatabaseEx(wstr long ptr)
|
@ stdcall SdbRegisterDatabaseEx(wstr long ptr)
|
||||||
|
|
|
@ -309,23 +309,29 @@ BasepCheckBadapp(IN HANDLE FileHandle,
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* @unimplemented
|
* @implemented
|
||||||
*/
|
*/
|
||||||
VOID
|
BOOL
|
||||||
WINAPI
|
WINAPI
|
||||||
BaseDumpAppcompatCache(VOID)
|
BaseDumpAppcompatCache(VOID)
|
||||||
{
|
{
|
||||||
STUB;
|
NTSTATUS Status;
|
||||||
|
|
||||||
|
Status = NtApphelpCacheControl(ApphelpCacheServiceDump, NULL);
|
||||||
|
return NT_SUCCESS(Status);
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* @unimplemented
|
* @implemented
|
||||||
*/
|
*/
|
||||||
VOID
|
BOOL
|
||||||
WINAPI
|
WINAPI
|
||||||
BaseFlushAppcompatCache(VOID)
|
BaseFlushAppcompatCache(VOID)
|
||||||
{
|
{
|
||||||
STUB;
|
NTSTATUS Status;
|
||||||
|
|
||||||
|
Status = NtApphelpCacheControl(ApphelpCacheServiceFlush, NULL);
|
||||||
|
return NT_SUCCESS(Status);
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
|
|
@ -764,6 +764,7 @@ NtApphelpCacheControl(
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
case ApphelpCacheServiceFlush:
|
case ApphelpCacheServiceFlush:
|
||||||
|
/* FIXME: Check for admin or system here. */
|
||||||
Status = ApphelpCacheFlush();
|
Status = ApphelpCacheFlush();
|
||||||
break;
|
break;
|
||||||
case ApphelpCacheServiceDump:
|
case ApphelpCacheServiceDump:
|
||||||
|
|
Loading…
Reference in a new issue