Skip to content
Snippets Groups Projects
Commit 9d263176 authored by Richard T. Carback III's avatar Richard T. Carback III
Browse files

Merge branch 'cherry-pick-aeda2104' into 'release'

Merge branch 'XX-4101/qrCodePanic' into 'master'

See merge request !49
parents 1b256324 3ede4962
Branches
Tags
2 merge requests!65Updates for Channel Support,!49Merge branch 'XX-4101/qrCodePanic' into 'master'
...@@ -17,6 +17,7 @@ import ( ...@@ -17,6 +17,7 @@ import (
"encoding/binary" "encoding/binary"
"encoding/gob" "encoding/gob"
"encoding/json" "encoding/json"
"github.com/pkg/errors"
jww "github.com/spf13/jwalterweatherman" jww "github.com/spf13/jwalterweatherman"
"gitlab.com/xx_network/crypto/csprng" "gitlab.com/xx_network/crypto/csprng"
"gitlab.com/xx_network/crypto/large" "gitlab.com/xx_network/crypto/large"
...@@ -165,9 +166,12 @@ func (g *Group) NewIntFromBits(b large.Bits) *Int { ...@@ -165,9 +166,12 @@ func (g *Group) NewIntFromBits(b large.Bits) *Int {
func (g *Group) checkInts(ints ...*Int) { func (g *Group) checkInts(ints ...*Int) {
for _, i := range ints { for _, i := range ints {
if i.GetGroupFingerprint() != g.fingerprint { if i.GetGroupFingerprint() != g.fingerprint {
jww.FATAL.Panicf("cyclicInt being used in wrong group! "+ // The error is created separately to ensure that the stack trace is
// printed on panic
err := errors.Errorf("cyclicInt being used in wrong group! "+
"Group fingerprint is %d and cyclicInt has %d", "Group fingerprint is %d and cyclicInt has %d",
g.fingerprint, i.GetGroupFingerprint()) g.fingerprint, i.GetGroupFingerprint())
jww.FATAL.Panicf("%+v", err)
} }
} }
} }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment