funding: replace fundingLocked with channelReady
This commit is contained in:
1 file changed
+6
-6
+6
-6
@@ -605,7 +605,7 @@ func (c channelOpeningState) String() string {
|
|||||||
case markedOpen:
|
case markedOpen:
|
||||||
return "markedOpen"
|
return "markedOpen"
|
||||||
case channelReadySent:
|
case channelReadySent:
|
||||||
return "fundingLocked"
|
return "channelReady"
|
||||||
case addedToRouterGraph:
|
case addedToRouterGraph:
|
||||||
return "addedToRouterGraph"
|
return "addedToRouterGraph"
|
||||||
default:
|
default:
|
||||||
@@ -1004,7 +1004,7 @@ func (f *Manager) stateStep(channel *channeldb.OpenChannel,
|
|||||||
case markedOpen:
|
case markedOpen:
|
||||||
err := f.sendChannelReady(channel, lnChannel)
|
err := f.sendChannelReady(channel, lnChannel)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return fmt.Errorf("failed sending fundingLocked: %v",
|
return fmt.Errorf("failed sending channelReady: %v",
|
||||||
err)
|
err)
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -1018,7 +1018,7 @@ func (f *Manager) stateStep(channel *channeldb.OpenChannel,
|
|||||||
)
|
)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return fmt.Errorf("error setting channel state to"+
|
return fmt.Errorf("error setting channel state to"+
|
||||||
" fundingLockedSent: %v", err)
|
" channelReadySent: %v", err)
|
||||||
}
|
}
|
||||||
|
|
||||||
log.Debugf("Channel(%v) with ShortChanID %v: successfully "+
|
log.Debugf("Channel(%v) with ShortChanID %v: successfully "+
|
||||||
@@ -2998,7 +2998,7 @@ func (f *Manager) sendChannelReady(completeChan *channeldb.OpenChannel,
|
|||||||
break
|
break
|
||||||
}
|
}
|
||||||
|
|
||||||
log.Warnf("Unable to send fundingLocked to peer %x: %v. "+
|
log.Warnf("Unable to send channelReady to peer %x: %v. "+
|
||||||
"Will retry when online", peerKey, err)
|
"Will retry when online", peerKey, err)
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -3406,7 +3406,7 @@ func (f *Manager) handleChannelReady(peer lnpeer.Peer,
|
|||||||
f.handleChannelReadyMtx.Lock()
|
f.handleChannelReadyMtx.Lock()
|
||||||
_, ok := f.handleChannelReadyBarriers[msg.ChanID]
|
_, ok := f.handleChannelReadyBarriers[msg.ChanID]
|
||||||
if ok {
|
if ok {
|
||||||
log.Infof("Already handling fundingLocked for "+
|
log.Infof("Already handling channelReady for "+
|
||||||
"ChannelID(%v), ignoring.", msg.ChanID)
|
"ChannelID(%v), ignoring.", msg.ChanID)
|
||||||
f.handleChannelReadyMtx.Unlock()
|
f.handleChannelReadyMtx.Unlock()
|
||||||
return
|
return
|
||||||
@@ -3541,7 +3541,7 @@ func (f *Manager) handleChannelReady(peer lnpeer.Peer,
|
|||||||
// commitment point, since another pedantic implementation might
|
// commitment point, since another pedantic implementation might
|
||||||
// verify it.
|
// verify it.
|
||||||
if channel.RemoteNextRevocation != nil {
|
if channel.RemoteNextRevocation != nil {
|
||||||
log.Infof("Received duplicate fundingLocked for "+
|
log.Infof("Received duplicate channelReady for "+
|
||||||
"ChannelID(%v), ignoring.", chanID)
|
"ChannelID(%v), ignoring.", chanID)
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in new issue
Block a user