Skip to content

Commit

Permalink
Merge pull request #141 from nspcc-dev/fix-sigsegv
Browse files Browse the repository at this point in the history
  • Loading branch information
roman-khimov authored Jun 19, 2024
2 parents 323f1c3 + 1628d32 commit a6d7592
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion pkg/pool/pool.go
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,7 @@ func (p *Pool) recheck(ctx context.Context) {
if cl == nil || err != nil {
p.clients[i], err = neoGoClient(ctx, p.endpoints[i], p.opts)
if err != nil {
log.Printf("reconnect to Neo node %s failed: %v", cl.Endpoint(), err)
log.Printf("reconnect to Neo node %s failed: %v", p.endpoints[i], err)
}

continue
Expand Down Expand Up @@ -319,6 +319,9 @@ func (p *Pool) FetchHeight() []monitor.HeightData {
)

for _, cl := range p.clients {
if cl == nil {
continue
}
wg.Add(1)

go func(cl *rpcclient.Client) {
Expand Down Expand Up @@ -358,6 +361,9 @@ func (p *Pool) FetchState(height uint32) []monitor.StateData {
)

for _, cl := range p.clients {
if cl == nil {
continue
}
wg.Add(1)

go func(cl *rpcclient.Client) {
Expand Down

0 comments on commit a6d7592

Please sign in to comment.