Bug #2518
Updated by Alex Afanasyev almost 10 years ago
Pseudocode to trigger the problem:
shared_ptr<Face> face = make_shared<Face>();
boost::thread t = boost::thread([&face] {
boost::this_thread::sleep_for(time::milliseconds(55));
face.getIoService().post([&face] {
face.reset();
});
});
face->expressInterest(Interest("/Hello/World", time::milliseconds(50)),
bind([]{}), bind([]{}));
face->processEvents();
Destructing the face should have caused all handlers posted to io service to be cancelled and processEvents() should have been terminated with no error.
Actual: segfault