chriskohlhoff / asio

Asio C++ Library
http://think-async.com/Asio
4.85k stars 1.2k forks source link

shutdown() in io_context destructor #1247

Closed ecatmur closed 1 year ago

ecatmur commented 1 year ago

Fixes use-after-destroy when shutdown() called from base execution_context destructor ends up calling work_finished() and accessing iocontext::impl data member. Fixes #1245.

ecatmur commented 1 year ago

Fixed by https://github.com/chriskohlhoff/asio/commit/1408e2895c94c8e254e9e8ddd66ba083777f0dc2 (other than documentation)