From 0372bf931978b9f69e7df97a7e8c53c254c72552 Mon Sep 17 00:00:00 2001 From: Conner Fromknecht Date: Fri, 27 Jul 2018 02:22:48 -0700 Subject: [PATCH] htlcswitch/circuit_map: prevent spewing secp curve in trace Replaces the log statement in CommitCircuits so that it prints the circuit key of the incoming channel. This way we avoid spewing the secp curve stored in the ErrorEncrypter. --- htlcswitch/circuit_map.go | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/htlcswitch/circuit_map.go b/htlcswitch/circuit_map.go index 0e56d43e..3b605bbd 100644 --- a/htlcswitch/circuit_map.go +++ b/htlcswitch/circuit_map.go @@ -495,8 +495,13 @@ func (cm *circuitMap) LookupByPaymentHash(hash [32]byte) []*PaymentCircuit { func (cm *circuitMap) CommitCircuits(circuits ...*PaymentCircuit) ( *CircuitFwdActions, error) { + inKeys := make([]CircuitKey, 0, len(circuits)) + for _, circuit := range circuits { + inKeys = append(inKeys, circuit.Incoming) + } + log.Tracef("Committing fresh circuits: %v", newLogClosure(func() string { - return spew.Sdump(circuits) + return spew.Sdump(inKeys) })) actions := &CircuitFwdActions{}