Skip to content

Commit 0d11eb1

Browse files
committed
[APPHELP] Add noisy stub for SdbGetDatabaseInformationByName
1 parent b3a0b41 commit 0d11eb1

File tree

5 files changed

+25
-10
lines changed

5 files changed

+25
-10
lines changed

dll/appcompat/apphelp/apphelp.c

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -291,7 +291,6 @@ BOOL WINAPI SdbRegisterDatabaseEx(
291291
if (!SdbGUIDToString(&Information.Id, GuidBuffer, RTL_NUMBER_OF(GuidBuffer)))
292292
{
293293
SHIM_ERR("Unable to Convert GUID to string\n");
294-
SdbFreeDatabaseInformation(&Information);
295294
SdbCloseDatabase(pdb);
296295
return FALSE;
297296
}
@@ -374,7 +373,6 @@ BOOL WINAPI SdbRegisterDatabaseEx(
374373
SHIM_ERR("Unable to create key %wZ\n", &KeyName);
375374
}
376375

377-
SdbFreeDatabaseInformation(&Information);
378376
SdbCloseDatabase(pdb);
379377

380378
return NT_SUCCESS(Status);

dll/appcompat/apphelp/apphelp.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -109,7 +109,7 @@ LPWSTR WINAPI SdbGetStringTagPtr(PDB pdb, TAGID tagid);
109109
TAGID WINAPI SdbFindFirstNamedTag(PDB pdb, TAGID root, TAGID find, TAGID nametag, LPCWSTR find_name);
110110
DWORD WINAPI SdbQueryDataExTagID(PDB pdb, TAGID tiExe, LPCWSTR lpszDataName, LPDWORD lpdwDataType, LPVOID lpBuffer, LPDWORD lpcbBufferSize, TAGID *ptiData);
111111
BOOL WINAPI SdbGetDatabaseInformation(PDB pdb, PDB_INFORMATION information);
112-
VOID WINAPI SdbFreeDatabaseInformation(PDB_INFORMATION information);
112+
VOID WINAPI SdbFreeDatabaseInformation(_In_opt_ PDB_INFORMATION information);
113113
BOOL WINAPI SdbRegisterDatabaseEx(_In_ LPCWSTR pszDatabasePath, _In_ DWORD dwDatabaseType, _In_opt_ const PULONGLONG pTimeStamp);
114114
BOOL WINAPI SdbUnregisterDatabase(_In_ const GUID *pguidDB);
115115

dll/appcompat/apphelp/apphelp.spec

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@
5656
@ stdcall SdbGetBinaryTagData(ptr long)
5757
@ stdcall SdbGetDatabaseID(ptr ptr)
5858
@ stdcall SdbGetDatabaseInformation(ptr ptr)
59-
@ stub SdbGetDatabaseInformationByName
59+
@ stdcall SdbGetDatabaseInformationByName(wstr ptr)
6060
@ stub SdbGetDatabaseMatch
6161
@ stdcall SdbGetDatabaseVersion(wstr ptr ptr)
6262
@ stub SdbGetDllPath

dll/appcompat/apphelp/sdbapi.c

Lines changed: 22 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -521,16 +521,33 @@ BOOL WINAPI SdbGetDatabaseInformation(PDB pdb, PDB_INFORMATION information)
521521
}
522522

523523
/**
524-
* @name SdbFreeDatabaseInformation
525-
* Free up resources allocated in SdbGetDatabaseInformation
524+
* @unimplemented
525+
* @name SdbGetDatabaseInformationByName
526+
* Get information about the database
526527
*
527-
* @param information The information retrieved from SdbGetDatabaseInformation
528+
* @param lpwszFileName The database file
529+
* @param ppAttrInfo The returned information, allocated by this function
530+
* @return TRUE on success
528531
*/
529-
VOID WINAPI SdbFreeDatabaseInformation(PDB_INFORMATION information)
532+
BOOL WINAPI
533+
SdbGetDatabaseInformationByName(_In_ LPCTSTR lpwszFileName, _Outptr_ PDB_INFORMATION *ppAttrInfo)
530534
{
531-
// No-op
535+
SHIM_ERR("Unimplemented\n");
536+
*ppAttrInfo = NULL;
537+
return FALSE;
532538
}
533539

540+
/**
541+
* @unimplemented
542+
* @name SdbFreeDatabaseInformation
543+
* Free up resources allocated in SdbGetDatabaseInformationByName
544+
*
545+
* @param information The information retrieved from SdbGetDatabaseInformationByName
546+
*/
547+
VOID WINAPI SdbFreeDatabaseInformation(_In_opt_ PDB_INFORMATION information)
548+
{
549+
SHIM_ERR("Unimplemented\n");
550+
}
534551

535552
/**
536553
* Find the first named child tag.

dll/ntdll/ldr/ldrapi.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1631,7 +1631,7 @@ LdrFlushAlternateResourceModules(VOID)
16311631

16321632
/*
16331633
* @unimplemented
1634-
* See https://www.kernelmode.info/forum/viewtopic.php?t=991
1634+
* See https://web.archive.org/web/20231210142610/https://kernelmode.info/forum/viewtopic3973.html?t=991
16351635
*/
16361636
NTSTATUS
16371637
NTAPI

0 commit comments

Comments
 (0)