aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorobscuren <geffobscura@gmail.com>2015-03-20 19:52:03 +0800
committerobscuren <geffobscura@gmail.com>2015-03-20 19:52:03 +0800
commit4f5b362bda862b0d77583491d5e04193148a9349 (patch)
treefc00b04aaaebb3dae1e87a1870463e2c8016dcdb
parent91f9f355b2e334214e38e1827c624cdcc23c5130 (diff)
downloaddexon-4f5b362bda862b0d77583491d5e04193148a9349.tar
dexon-4f5b362bda862b0d77583491d5e04193148a9349.tar.gz
dexon-4f5b362bda862b0d77583491d5e04193148a9349.tar.bz2
dexon-4f5b362bda862b0d77583491d5e04193148a9349.tar.lz
dexon-4f5b362bda862b0d77583491d5e04193148a9349.tar.xz
dexon-4f5b362bda862b0d77583491d5e04193148a9349.tar.zst
dexon-4f5b362bda862b0d77583491d5e04193148a9349.zip
%#x => %x
-rw-r--r--cmd/ethereum/main.go2
-rw-r--r--p2p/discover/node.go4
-rw-r--r--p2p/message.go2
3 files changed, 4 insertions, 4 deletions
diff --git a/cmd/ethereum/main.go b/cmd/ethereum/main.go
index 1a662c756..87f588de8 100644
--- a/cmd/ethereum/main.go
+++ b/cmd/ethereum/main.go
@@ -251,7 +251,7 @@ func accountList(ctx *cli.Context) {
utils.Fatalf("Could not list accounts: %v", err)
}
for _, acct := range accts {
- fmt.Printf("Address: %#x\n", acct)
+ fmt.Printf("Address: %x\n", acct)
}
}
diff --git a/p2p/discover/node.go b/p2p/discover/node.go
index de2588258..e1130e0b5 100644
--- a/p2p/discover/node.go
+++ b/p2p/discover/node.go
@@ -143,12 +143,12 @@ type NodeID [nodeIDBits / 8]byte
// NodeID prints as a long hexadecimal number.
func (n NodeID) String() string {
- return fmt.Sprintf("%#x", n[:])
+ return fmt.Sprintf("%x", n[:])
}
// The Go syntax representation of a NodeID is a call to HexID.
func (n NodeID) GoString() string {
- return fmt.Sprintf("discover.HexID(\"%#x\")", n[:])
+ return fmt.Sprintf("discover.HexID(\"%x\")", n[:])
}
// HexID converts a hex string to a NodeID.
diff --git a/p2p/message.go b/p2p/message.go
index 14e4404c9..31cf5901f 100644
--- a/p2p/message.go
+++ b/p2p/message.go
@@ -40,7 +40,7 @@ func NewMsg(code uint64, params ...interface{}) Msg {
// For the decoding rules, please see package rlp.
func (msg Msg) Decode(val interface{}) error {
if err := rlp.Decode(msg.Payload, val); err != nil {
- return newPeerError(errInvalidMsg, "(code %#x) (size %d) %v", msg.Code, msg.Size, err)
+ return newPeerError(errInvalidMsg, "(code %x) (size %d) %v", msg.Code, msg.Size, err)
}
return nil
}