Commit 28f3e1c6 authored by Dominik Charousset's avatar Dominik Charousset

Fix initialization of typed brokers

parent 9dea9baa
...@@ -287,11 +287,11 @@ private: ...@@ -287,11 +287,11 @@ private:
auto init = fac(std::move(fun), std::forward<Ts>(xs)...); auto init = fac(std::move(fun), std::forward<Ts>(xs)...);
auto hdl = backend().new_tcp_doorman(port).first; auto hdl = backend().new_tcp_doorman(port).first;
actor_config cfg{&backend()}; actor_config cfg{&backend()};
cfg.init_fun = [hdl](local_actor* ptr) -> behavior { cfg.init_fun = [hdl, init](local_actor* ptr) -> behavior {
static_cast<abstract_broker*>(ptr)->assign_tcp_doorman(hdl); static_cast<abstract_broker*>(ptr)->assign_tcp_doorman(hdl);
return init(ptr); return init(ptr);
}; };
return system().spawn_class<Os, Impl>(cfg); return system().spawn_class<Impl, Os>(cfg);
} }
uint16_t publish(const actor_addr& whom, std::set<std::string> sigs, uint16_t publish(const actor_addr& whom, std::set<std::string> sigs,
......
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