}
cleanup:
- RevertToSelf();
if (Session->hUserActivity)
CloseHandle(Session->hUserActivity);
if (Session->hEndOfScreenSaver)
CloseHandle(Session->hEndOfScreenSaver);
+ RevertToSelf();
+
#ifndef USE_GETLASTINPUTINFO
if (Session->KeyboardHook)
UnhookWindowsHookEx(Session->KeyboardHook);
CloseHandle(Session->hEndOfScreenSaverThread);
CloseHandle(Session->hScreenSaverParametersChanged);
+
return 0;
}
SystemParametersInfoW(SPI_SETSCREENSAVERRUNNING, TRUE, NULL, 0);
+ CallNotificationDlls(Session, StartScreenSaverHandler);
+
/* Wait the end of the process or some other activity */
ResetEvent(Session->hUserActivity);
HandleArray[0] = ProcessInformation.hProcess;
CloseHandle(ProcessInformation.hProcess);
+ CallNotificationDlls(Session, StopScreenSaverHandler);
+
cleanup:
- RevertToSelf();
if (hKey)
RegCloseKey(hKey);
if (hCurrentUser)
RegCloseKey(hCurrentUser);
+ RevertToSelf();
+
if (!ret)
{
PostMessageW(Session->SASWindow, WLX_WM_SAS, WLX_SAS_TYPE_SCRNSVR_ACTIVITY, 0);