You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
If you take the example test program test_running.cpp and add a asio/signal_set handler to trap Ctrl-C there doesn't appear to be a way to remove the async_monitor operation thus io_service.run() never exits.
In my application our Ctrl-C handler gracefully tells all asio io_objects (timers, sockets) to "shutdown". Then the io_service exits once all the handlers have executed and the program drops out of the bottom of main.
Even calling remove_directory in the Ctrl-C handler appears to keep the work on the queue.