diff options
author | Taylor Gerring <taylor.gerring@gmail.com> | 2015-01-21 03:22:38 +0800 |
---|---|---|
committer | Taylor Gerring <taylor.gerring@gmail.com> | 2015-01-21 03:22:38 +0800 |
commit | d92fde698031758f64fcabe7af354360a93f6326 (patch) | |
tree | 5f843fe17762e0aa87a0e790d527886f2cc8eea5 /ethutil | |
parent | 499bc404e818848e53c8c7f4f6d1bfe2349e97ae (diff) | |
parent | 87f50659db7a4bf194769b05f541d2ccf02f4fc8 (diff) | |
download | go-tangerine-d92fde698031758f64fcabe7af354360a93f6326.tar go-tangerine-d92fde698031758f64fcabe7af354360a93f6326.tar.gz go-tangerine-d92fde698031758f64fcabe7af354360a93f6326.tar.bz2 go-tangerine-d92fde698031758f64fcabe7af354360a93f6326.tar.lz go-tangerine-d92fde698031758f64fcabe7af354360a93f6326.tar.xz go-tangerine-d92fde698031758f64fcabe7af354360a93f6326.tar.zst go-tangerine-d92fde698031758f64fcabe7af354360a93f6326.zip |
Merge branch 'develop' into jsonrpc
Diffstat (limited to 'ethutil')
-rw-r--r-- | ethutil/common.go | 1 | ||||
-rw-r--r-- | ethutil/config.go | 2 | ||||
-rw-r--r-- | ethutil/path.go | 2 | ||||
-rw-r--r-- | ethutil/rlp.go | 2 |
4 files changed, 3 insertions, 4 deletions
diff --git a/ethutil/common.go b/ethutil/common.go index 0a29cac6c..271c56fd5 100644 --- a/ethutil/common.go +++ b/ethutil/common.go @@ -84,4 +84,5 @@ var ( BigFalse = Big0 Big32 = big.NewInt(32) Big256 = big.NewInt(0xff) + Big257 = big.NewInt(257) ) diff --git a/ethutil/config.go b/ethutil/config.go index ccc7714d0..fc8fb4e3f 100644 --- a/ethutil/config.go +++ b/ethutil/config.go @@ -10,8 +10,6 @@ import ( // Config struct type ConfigManager struct { - Db Database - ExecPath string Debug bool Diff bool diff --git a/ethutil/path.go b/ethutil/path.go index f64e3849e..e545c8731 100644 --- a/ethutil/path.go +++ b/ethutil/path.go @@ -12,7 +12,7 @@ func ExpandHomePath(p string) (path string) { path = p // Check in case of paths like "/something/~/something/" - if path[:2] == "~/" { + if len(path) > 1 && path[:2] == "~/" { usr, _ := user.Current() dir := usr.HomeDir diff --git a/ethutil/rlp.go b/ethutil/rlp.go index 1bc1a58a7..0cb0d611c 100644 --- a/ethutil/rlp.go +++ b/ethutil/rlp.go @@ -137,7 +137,7 @@ func Encode(object interface{}) []byte { case byte: buff.Write(Encode(big.NewInt(int64(t)))) case *big.Int: - // Not sure how this is possible while we check for + // Not sure how this is possible while we check for nil if t == nil { buff.WriteByte(0xc0) } else { |