Potential issue with message_box() function
- Posted by LarryMiller Feb 17, 2016
- 1720 views
Internally the message_box() function uses the API function GetActiveWindow() to get the handle to the active window and uses that as it's parent. There are some potentially serious issues with this. The correct way is to pass the handle of your applications window, not that of a window that just happens to be active at the time.
Raymond Chen, a long time Microsoft developer, talks about this issue here: https://blogs.msdn.microsoft.com/oldnewthing/20070727-00/?p=25823/
What if anything should be done about this I will leave to the developers.