Commit 8aef33d3 authored by Dominik Charousset's avatar Dominik Charousset

maintenance

parent c7f82fad
...@@ -94,12 +94,11 @@ void yielding_actor::dequeue(partial_function& fun) { ...@@ -94,12 +94,11 @@ void yielding_actor::dequeue(partial_function& fun) {
void yielding_actor::dequeue(behavior& bhvr) { void yielding_actor::dequeue(behavior& bhvr) {
if (bhvr.timeout().valid() == false) { if (bhvr.timeout().valid() == false) {
// suppress virtual function call m_recv_policy.receive(this, bhvr.get_partial_function());
yielding_actor::dequeue(bhvr.get_partial_function());
} }
else if (m_recv_policy.invoke_from_cache(this, bhvr) == false) { else if (m_recv_policy.invoke_from_cache(this, bhvr) == false) {
if (bhvr.timeout().is_zero()) { if (bhvr.timeout().is_zero()) {
for (auto e = m_mailbox.try_pop(); e != nullptr; e = m_mailbox.try_pop()) { for (auto e = m_mailbox.try_pop(); e != 0; e = m_mailbox.try_pop()) {
CPPA_REQUIRE(e->marked == false); CPPA_REQUIRE(e->marked == false);
if (m_recv_policy.invoke(this, e, bhvr)) return; if (m_recv_policy.invoke(this, e, bhvr)) return;
} }
...@@ -140,8 +139,7 @@ void yielding_actor::resume(util::fiber* from, scheduler::callback* callback) { ...@@ -140,8 +139,7 @@ void yielding_actor::resume(util::fiber* from, scheduler::callback* callback) {
break; break;
} }
default: { default: {
// illegal state CPPA_CRITICAL("illegal state");
exit(8);
} }
} }
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment