From 6f9718596d7bb7b954f74975897020846d8670a7 Mon Sep 17 00:00:00 2001 From: Sarah Jamie Lewis Date: Wed, 9 May 2018 12:40:07 -0700 Subject: [PATCH] fmt and travis update --- .travis.yml | 1 + connection/channelmanager.go | 2 +- connection/control_channel.go | 1 - utils/crypto.go | 6 +++--- utils/error.go | 2 +- 5 files changed, 6 insertions(+), 6 deletions(-) diff --git a/.travis.yml b/.travis.yml index 3d524b3..a839bc7 100644 --- a/.travis.yml +++ b/.travis.yml @@ -12,6 +12,7 @@ install: - go get github.com/mattn/goveralls - go get golang.org/x/net/proxy - go get github.com/golang/protobuf/proto + - go get github.com/yawning/bulb/ script: diff --git a/connection/channelmanager.go b/connection/channelmanager.go index 745071d..6841c4f 100644 --- a/connection/channelmanager.go +++ b/connection/channelmanager.go @@ -12,7 +12,7 @@ type ChannelManager struct { channels map[int32]*channels.Channel nextFreeChannel int32 isClient bool - lock sync.Mutex // ChannelManager may be accessed by multiple thread, so we need to protect the map. + lock sync.Mutex // ChannelManager may be accessed by multiple thread, so we need to protect the map. } // NewClientChannelManager construsts a new channel manager enforcing behaviour diff --git a/connection/control_channel.go b/connection/control_channel.go index f312326..29b2935 100644 --- a/connection/control_channel.go +++ b/connection/control_channel.go @@ -6,7 +6,6 @@ import ( "github.com/s-rah/go-ricochet/wire/control" ) - // ControlChannel encapsulates logic for the control channel processing type ControlChannel struct { channelManager *ChannelManager diff --git a/utils/crypto.go b/utils/crypto.go index cec7874..2970349 100644 --- a/utils/crypto.go +++ b/utils/crypto.go @@ -6,10 +6,10 @@ import ( "crypto/x509" "encoding/pem" "errors" + "github.com/yawning/bulb/utils/pkcs1" "io/ioutil" "math" "math/big" - "github.com/yawning/bulb/utils/pkcs1" ) const ( @@ -20,7 +20,7 @@ const ( RicochetKeySize = 1024 ) -// GetRandNumber is a helper function which returns a random integer, this is +// GetRandNumber is a helper function which returns a random integer, this is // currently mostly used to generate messageids func GetRandNumber() *big.Int { num, err := rand.Int(rand.Reader, big.NewInt(math.MaxUint32)) @@ -80,4 +80,4 @@ func GetOnionAddress(privateKey *rsa.PrivateKey) (string, error) { return "", OnionAddressGenerationError } return addr, nil -} \ No newline at end of file +} diff --git a/utils/error.go b/utils/error.go index 002f465..6af25ae 100644 --- a/utils/error.go +++ b/utils/error.go @@ -40,7 +40,7 @@ const ( // Library Use Errors OnionAddressGenerationError = Error("OnionAddressGenerationError") - PrivateKeyNotSetError = Error("PrivateKeyNotSet") + PrivateKeyNotSetError = Error("PrivateKeyNotSet") // Connection Errors ConnectionClosedError = Error("ConnectionClosedError")