mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-10-26 21:49:49 +00:00
network: guard validation network future under exit signal (#167)
This commit is contained in:
1 parent
30472a18ab
commit
23d7f459a2
1 file changed
+2
-1
@@ -232,6 +232,7 @@ impl<P, E, N, T> ParachainNetwork for ValidationNetwork<P, E, N, T> where
|
||||
|
||||
let table_router_clone = table_router.clone();
|
||||
let executor = self.executor.clone();
|
||||
let exit = self.exit.clone();
|
||||
|
||||
// spin up a task in the background that processes all incoming statements
|
||||
// TODO: propagate statements on a timer?
|
||||
@@ -248,7 +249,7 @@ impl<P, E, N, T> ParachainNetwork for ValidationNetwork<P, E, N, T> where
|
||||
table_router: table_router_clone,
|
||||
};
|
||||
|
||||
executor.spawn(process_task);
|
||||
executor.spawn(process_task.select(exit).then(|_| Ok(())));
|
||||
});
|
||||
|
||||
table_router
|
||||
|
||||
Reference in new issue
Block a user