OS does not shut down, but my application

I have an application that, when I close Windows, exits elegantly and quickly (it is also checked in the task manager and Process Explorer - the process no longer exists), but the OS does not exist. The OS seems to just ignore Shutdown.

But if I try to close Windows again, now everything is in order. The system shuts down in a very normal way.

  • Why?
  • How can i fix this?

Details about my application:

  • multithreaded
  • has a tray icon.
  • does not perform any special processing of WM_QUERYENDSESSION messages (or the like)
  • does not have a special driver, DLL-hook, etc.

Any ideas how to fix this?

PS: I am at your disposal and details on request

+3
3

TRUE WM_QUERYENDSESSION ( )? , FALSE.

+1

, .

, , . , , , .

  • datamodule .
  • NMsmtp .
  • , , , .

NMsmtp, Indy.

, , , , , .

+1

Source: https://habr.com/ru/post/1728595/


All Articles