diff options
author | obscuren <geffobscura@gmail.com> | 2015-03-06 23:40:21 +0800 |
---|---|---|
committer | obscuren <geffobscura@gmail.com> | 2015-03-06 23:40:21 +0800 |
commit | 548e1041718ffc0ee0659f1ff99b37cad38190c0 (patch) | |
tree | dc354aae2e364e4a2a426efc0ca5f6412acfa980 /eth | |
parent | 8d9be18b296afb8302249dcc96651aabb0975e26 (diff) | |
parent | e64f727529287b7414af6d1f482ea5f318cbd2eb (diff) | |
download | dexon-548e1041718ffc0ee0659f1ff99b37cad38190c0.tar dexon-548e1041718ffc0ee0659f1ff99b37cad38190c0.tar.gz dexon-548e1041718ffc0ee0659f1ff99b37cad38190c0.tar.bz2 dexon-548e1041718ffc0ee0659f1ff99b37cad38190c0.tar.lz dexon-548e1041718ffc0ee0659f1ff99b37cad38190c0.tar.xz dexon-548e1041718ffc0ee0659f1ff99b37cad38190c0.tar.zst dexon-548e1041718ffc0ee0659f1ff99b37cad38190c0.zip |
Merge branch 'poc-9' of github.com-obscure:ethereum/go-ethereum into poc-9
Diffstat (limited to 'eth')
-rw-r--r-- | eth/backend.go | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/eth/backend.go b/eth/backend.go index 4e021a901..1c711a775 100644 --- a/eth/backend.go +++ b/eth/backend.go @@ -130,13 +130,15 @@ type Ethereum struct { logger logger.LogSystem - Mining bool + Mining bool + DataDir string } func New(config *Config) (*Ethereum, error) { // Boostrap database ethlogger := logger.New(config.DataDir, config.LogFile, config.LogLevel, config.LogFormat) - db, err := ethdb.NewLDBDatabase("blockchain") + + db, err := ethdb.NewLDBDatabase(path.Join(config.DataDir, "blockchain")) if err != nil { return nil, err } @@ -171,6 +173,7 @@ func New(config *Config) (*Ethereum, error) { keyManager: keyManager, eventMux: &event.TypeMux{}, logger: ethlogger, + DataDir: config.DataDir, } eth.chainManager = core.NewChainManager(db, eth.EventMux()) |