p2p/discover: code review fixes

This commit is contained in:
Felix Lange
2015-02-13 11:39:31 +01:00
parent d0a2e655c9
commit 82f0bd9009
3 changed files with 9 additions and 7 deletions
+3 -1
View File
@@ -18,6 +18,8 @@ import (
"github.com/ethereum/go-ethereum/rlp"
)
const nodeIDBits = 512
// Node represents a host on the network.
type Node struct {
ID NodeID
@@ -135,7 +137,7 @@ func (n *Node) DecodeRLP(s *rlp.Stream) (err error) {
// NodeID is a unique identifier for each node.
// The node identifier is a marshaled elliptic curve public key.
type NodeID [512 / 8]byte
type NodeID [nodeIDBits / 8]byte
// NodeID prints as a long hexadecimal number.
func (n NodeID) String() string {