mirror of
https://github.com/lightningnetwork/lnd.git
synced 2025-03-04 09:48:19 +01:00
htlcswitch: fix linter issues
This commit is contained in:
parent
1be4d67ce4
commit
4b0e331c62
3 changed files with 7 additions and 6 deletions
|
@ -77,7 +77,7 @@ test_race_conditions() {
|
||||||
check_test_ports
|
check_test_ports
|
||||||
|
|
||||||
test_targets=$(go list ./... | grep -v '/vendor/')
|
test_targets=$(go list ./... | grep -v '/vendor/')
|
||||||
env GORACE="halt_on_error=1" go test -p 1 -v -race $test_targets
|
env GORACE="halt_on_error=1" go test -v -race $test_targets
|
||||||
}
|
}
|
||||||
|
|
||||||
# lint_check runs static checks.
|
# lint_check runs static checks.
|
||||||
|
@ -166,4 +166,4 @@ if [ "$NEED_COVERAGE" == "true" ]; then
|
||||||
test_with_coverage_profile
|
test_with_coverage_profile
|
||||||
fi
|
fi
|
||||||
|
|
||||||
print "=====+ End +====="
|
print "=====+ End +====="
|
||||||
|
|
|
@ -944,7 +944,7 @@ func (l *channelLink) processLockedInHtlcs(
|
||||||
log.Errorf("Onion payload of incoming "+
|
log.Errorf("Onion payload of incoming "+
|
||||||
"htlc(%x) has incorrect time-lock: "+
|
"htlc(%x) has incorrect time-lock: "+
|
||||||
"expected %v, got %v",
|
"expected %v, got %v",
|
||||||
l.cfg.FwrdingPolicy.TimeLockDelta,
|
pd.RHash[:], l.cfg.FwrdingPolicy.TimeLockDelta,
|
||||||
fwdInfo.OutgoingCTLV)
|
fwdInfo.OutgoingCTLV)
|
||||||
|
|
||||||
reason := []byte{byte(lnwire.UpstreamTimeout)}
|
reason := []byte{byte(lnwire.UpstreamTimeout)}
|
||||||
|
@ -1061,7 +1061,8 @@ func (l *channelLink) processLockedInHtlcs(
|
||||||
log.Errorf("Incoming htlc(%x) has "+
|
log.Errorf("Incoming htlc(%x) has "+
|
||||||
"incorrect time-lock value: expected "+
|
"incorrect time-lock value: expected "+
|
||||||
"%v blocks, got %v blocks",
|
"%v blocks, got %v blocks",
|
||||||
pd.Timeout-timeDelta, fwdInfo.OutgoingCTLV)
|
pd.RHash[:], pd.Timeout-timeDelta,
|
||||||
|
fwdInfo.OutgoingCTLV)
|
||||||
|
|
||||||
// TODO(andrew.shvv): send proper back error
|
// TODO(andrew.shvv): send proper back error
|
||||||
reason := []byte{byte(lnwire.UpstreamTimeout)}
|
reason := []byte{byte(lnwire.UpstreamTimeout)}
|
||||||
|
|
|
@ -837,8 +837,8 @@ type getLinksCmd struct {
|
||||||
done chan []ChannelLink
|
done chan []ChannelLink
|
||||||
}
|
}
|
||||||
|
|
||||||
// GetLinks fetches all the links connected to a particular node identified by
|
// GetLinksByInterface fetches all the links connected to a particular node
|
||||||
// the serialized compressed form of its public key.
|
// identified by the serialized compressed form of its public key.
|
||||||
func (s *Switch) GetLinksByInterface(hop [33]byte) ([]ChannelLink, error) {
|
func (s *Switch) GetLinksByInterface(hop [33]byte) ([]ChannelLink, error) {
|
||||||
command := &getLinksCmd{
|
command := &getLinksCmd{
|
||||||
peer: hop,
|
peer: hop,
|
||||||
|
|
Loading…
Add table
Reference in a new issue