Perform step by step debugging. This is where the endless message fishing cycle comes in. How to get to the code that sends messages here?

void CRenderDevice::message_loop() { if (editor()) { message_loop_editor(); return; } MSG msg; PeekMessage(&msg, NULL, 0U, 0U, PM_NOREMOVE); while (msg.message != WM_QUIT) { if (PeekMessage(&msg, NULL, 0U, 0U, PM_REMOVE)) { TranslateMessage(&msg); DispatchMessage(&msg); continue; } on_idle(); } } 
  • If you are given an exhaustive answer, mark it as correct (a daw opposite the selected answer). - Nicolas Chabanovsky

1 answer 1

Automatically nothing, just analyze the program manually.

You have a letter in your inbox. What did the postman who brought him look like? Your problem is the same order.

Messages can come to the message queue from anywhere. Even any external application can post your message to your message queue. The message already lies in your mailbox (message queue), the postman left a long time ago (the part of the code that sent the message worked long ago).

You will have to rummage through the entire program, and find out where, in principle, this message can come from. The problem is complicated by the fact that some messages are sent to you automatically, so the code that actually sends them is in the depth of user32.dll, and the code that actually caused the message to be sent could be anywhere.