Make sure there are no outstanding timers in the destructor
authorChad Parry <cparry@fb.com>
Mon, 9 Nov 2015 18:39:22 +0000 (10:39 -0800)
committerfacebook-github-bot-9 <folly-bot@fb.com>
Mon, 9 Nov 2015 19:20:24 +0000 (11:20 -0800)
commita93b1f39a4e39fef73ffad8a9725e46bd93b7b07
tree01035941db9b62772e85c17644195e237a7c8706
parent408597e5bc528477608785709ba3fa67ef64823f
Make sure there are no outstanding timers in the destructor

Summary: This is the solution for our `HHWheelTimer` crashes, as suggested in D2617966#25.

djwatson also mentioned that maybe there should be some logging in the destructor if there are outstanding callbacks. I couldn't think of anything that would add to the `assert` that already exists in `destroy`. I'm open to suggestions though.

Reviewed By: djwatson

Differential Revision: D2628154

fb-gh-sync-id: f3db6e9384517c9bf3cbb60af8c1e711703a07fa
folly/io/async/HHWheelTimer.cpp