Usage of SetUserObjectInformation() Win32

drjackool 956 Reputation points
2021-09-16T16:40:02.85+00:00

Hi
In SetTimer() page wrotes:

Before using SetTimer or other timer-related functions, it is recommended to set the UOI_TIMERPROC_EXCEPTION_SUPPRESSION flag to false through the SetUserObjectInformationW function, otherwise the application could behave unpredictably and could be vulnerable to security exploits. For more info, see SetUserObjectInformationW.

But what is correct usage of this function?
Is this correct?
I place it in CApp::InitInstance()

BOOL bBool = FALSE;
SetUserObjectInformation(GetCurrentProcess(), UOI_TIMERPROC_EXCEPTION_SUPPRESSION, &bBool, sizeof(BOOL));

Thanks

Windows API - Win32
Windows API - Win32
A core set of Windows application programming interfaces (APIs) for desktop and server applications. Previously known as Win32 API.
2,431 questions
{count} votes

1 answer

Sort by: Most helpful
  1. drjackool 956 Reputation points
    2021-09-20T14:55:36.913+00:00

    solved.............

    0 comments No comments