Thanks a lot Katayama Hirofumi for the hint!
static VOID
AddUserProfile(
_In_ HWND hwndListView,
- _In_ PWSTR pszProfileSid,
_In_ PSID pProfileSid,
_In_ BOOL bMyProfile,
_In_ HKEY hProfileKey)
if (ConvertStringSidToSid(szProfileSid, &pProfileSid))
{
AddUserProfile(hwndListView,
- pszProfileSid,
pProfileSid,
EqualSid(pProfileSid, pTokenUser->User.Sid),
hProfileKey);
&hProfileKey) == ERROR_SUCCESS)
{
AddUserProfile(hwndListView,
- pszProfileSid,
pTokenUser->User.Sid,
TRUE,
hProfileKey);