https://git.reactos.org/?p=reactos.git;a=commitdiff;h=19304da5c3b725f979e081cd18e5290bf92e2080
commit 19304da5c3b725f979e081cd18e5290bf92e2080 Author: Pierre Schweitzer <pie...@reactos.org> AuthorDate: Sun Dec 30 11:52:37 2018 +0100 Commit: Pierre Schweitzer <pie...@reactos.org> CommitDate: Sun Dec 30 14:27:02 2018 +0100 [ADVAPI32] Implement I_QueryTagInformation --- dll/win32/advapi32/advapi32.spec | 2 +- dll/win32/advapi32/service/scm.c | 44 ++++++++++++++++++++++++++++++++++++++++ 2 files changed, 45 insertions(+), 1 deletion(-) diff --git a/dll/win32/advapi32/advapi32.spec b/dll/win32/advapi32/advapi32.spec index 3414463328..5a571db55a 100644 --- a/dll/win32/advapi32/advapi32.spec +++ b/dll/win32/advapi32/advapi32.spec @@ -294,7 +294,7 @@ 294 stdcall GetUserNameA(ptr ptr) 295 stdcall GetUserNameW(ptr ptr) 296 stdcall GetWindowsAccountDomainSid(ptr ptr ptr) -297 stub I_QueryTagInformation +297 stdcall I_QueryTagInformation(ptr long ptr) 298 stdcall I_ScIsSecurityProcess() 299 stdcall I_ScPnPGetServiceName(ptr wstr long) 300 stub I_ScSendTSMessage diff --git a/dll/win32/advapi32/service/scm.c b/dll/win32/advapi32/service/scm.c index 1fe96213a1..08baad1cb9 100644 --- a/dll/win32/advapi32/service/scm.c +++ b/dll/win32/advapi32/service/scm.c @@ -3022,4 +3022,48 @@ NotifyBootConfigStatus(BOOL BootAcceptable) return TRUE; } +DWORD +I_ScQueryServiceTagInfo(PVOID Unused, + TAG_INFO_LEVEL dwInfoLevel, + PTAG_INFO_NAME_FROM_TAG InOutParams) +{ + return ERROR_CALL_NOT_IMPLEMENTED; +} + +/********************************************************************** + * I_QueryTagInformation + * + * @implemented + */ +DWORD WINAPI +I_QueryTagInformation(PVOID Unused, + TAG_INFO_LEVEL dwInfoLevel, + PTAG_INFO_NAME_FROM_TAG InOutParams) +{ + /* + * We only support one information class and it + * needs parameters + */ + if (dwInfoLevel != TagInfoLevelNameFromTag || + InOutParams == NULL) + { + return ERROR_INVALID_PARAMETER; + } + + /* Validate input structure */ + if (InOutParams->InParams.dwPid == 0 || InOutParams->InParams.dwTag == 0) + { + return ERROR_INVALID_PARAMETER; + } + + /* Validate output structure */ + if (InOutParams->OutParams.pszName != NULL) + { + return ERROR_INVALID_PARAMETER; + } + + /* Call internal function for the RPC call */ + return I_ScQueryServiceTagInfo(Unused, TagInfoLevelNameFromTag, InOutParams); +} + /* EOF */