autopilot: ensure access to pendingOpens in thread-safe when logging
This commit is contained in:
1 file changed
+2
@@ -321,7 +321,9 @@ func (a *Agent) controller(startingBalance btcutil.Amount) {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
pendingMtx.Lock()
|
||||||
log.Debugf("Pending channels: %v", spew.Sdump(pendingOpens))
|
log.Debugf("Pending channels: %v", spew.Sdump(pendingOpens))
|
||||||
|
pendingMtx.Unlock()
|
||||||
|
|
||||||
// With all the updates applied, we'll obtain a set of
|
// With all the updates applied, we'll obtain a set of
|
||||||
// the current active channels (confirmed channels),
|
// the current active channels (confirmed channels),
|
||||||
|
|||||||
Reference in new issue
Block a user