Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我有一个控制台应用程序,它可能需要超过 5 秒才能正常关闭。但是,如果用户单击标题栏上的关闭按钮,windows 似乎会强制终止应用程序。通过使用SetConsoleCtrlHandler,我设法将终止延迟了 5 秒。有没有办法延长这个延迟?