multi: wait for rpcclients shutdown to complete

We need to call `WaitForShutdown` after stopping the rpc clients of the
chain backends.
This commit is contained in:
yyforyongyu committed 2024-11-14 01:22:31 +08:00
1 parent 304c8df7b9
commit 523ecc0653
7 files changed
+8 -4

No files matched your search

+1 -1
View File
@@ -180,7 +180,7 @@ func (b *BtcdNotifier) Stop() error {
// Shutdown the rpc client, this gracefully disconnects from btcd, and
// cleans up all related resources.
b.chainConn.Shutdown()
b.chainConn.Stop()
close(b.quit)
b.wg.Wait()