fix(test): hold owning ServiceHandle across hot-reload calls in FsmServiceHotReload

This commit is contained in:
faumaray committed 2026-11-26 17:10:54 +03:00
1 parent 1a54f3857e
commit cb988fa985
1 file changed
+5 -2
+5 -2
View File
@@ -50,8 +50,11 @@ namespace
struct Work : State {
Task<StateKey> run()
{
auto& svc = service<VoidTest::ICalc>();
const int total = svc.accumulate(1);
auto svc = acquire_service<VoidTest::ICalc>();
if (!svc) {
co_return next<Work>();
}
const int total = (*svc)->accumulate(1);
if (total >= 500) {
co_return succeed(total);
}