diff options
author | obscuren <geffobscura@gmail.com> | 2015-03-19 01:42:21 +0800 |
---|---|---|
committer | obscuren <geffobscura@gmail.com> | 2015-03-19 01:42:21 +0800 |
commit | af9da83ce2c6b0ab3047bfa2544b6914a2c4e2ea (patch) | |
tree | e254b7ed4a98d5b1d2fecfcbd4add9ad345a87b5 /eth/peer_util.go | |
parent | e30c32339132d678b428ae531932a3f048665f59 (diff) | |
parent | c12046d6bfb197adb0004d629a783dd92f0cfc0f (diff) | |
download | dexon-af9da83ce2c6b0ab3047bfa2544b6914a2c4e2ea.tar dexon-af9da83ce2c6b0ab3047bfa2544b6914a2c4e2ea.tar.gz dexon-af9da83ce2c6b0ab3047bfa2544b6914a2c4e2ea.tar.bz2 dexon-af9da83ce2c6b0ab3047bfa2544b6914a2c4e2ea.tar.lz dexon-af9da83ce2c6b0ab3047bfa2544b6914a2c4e2ea.tar.xz dexon-af9da83ce2c6b0ab3047bfa2544b6914a2c4e2ea.tar.zst dexon-af9da83ce2c6b0ab3047bfa2544b6914a2c4e2ea.zip |
Merge branch 'develop' into rpcfrontier
Diffstat (limited to 'eth/peer_util.go')
-rw-r--r-- | eth/peer_util.go | 23 |
1 files changed, 0 insertions, 23 deletions
diff --git a/eth/peer_util.go b/eth/peer_util.go deleted file mode 100644 index 18fef0ab5..000000000 --- a/eth/peer_util.go +++ /dev/null @@ -1,23 +0,0 @@ -package eth - -import ( - "encoding/json" - - "github.com/ethereum/go-ethereum/common" -) - -func WritePeers(path string, addresses []string) { - if len(addresses) > 0 { - data, _ := json.MarshalIndent(addresses, "", " ") - common.WriteFile(path, data) - } -} - -func ReadPeers(path string) (ips []string, err error) { - var data string - data, err = common.ReadAllFile(path) - if err != nil { - json.Unmarshal([]byte(data), &ips) - } - return -} |