diff options
author | Felix Lange <fjl@twurst.com> | 2015-03-06 21:02:16 +0800 |
---|---|---|
committer | Felix Lange <fjl@twurst.com> | 2015-03-06 21:02:16 +0800 |
commit | e64f727529287b7414af6d1f482ea5f318cbd2eb (patch) | |
tree | f1939dffc5973597e6da17ef60ad2044af7f4340 /eth | |
parent | a91bf014295bfaebee976f9e0e994e8a83e8e356 (diff) | |
parent | de86403f330e68df8fc4aee00df98374b7842d0d (diff) | |
download | go-tangerine-e64f727529287b7414af6d1f482ea5f318cbd2eb.tar go-tangerine-e64f727529287b7414af6d1f482ea5f318cbd2eb.tar.gz go-tangerine-e64f727529287b7414af6d1f482ea5f318cbd2eb.tar.bz2 go-tangerine-e64f727529287b7414af6d1f482ea5f318cbd2eb.tar.lz go-tangerine-e64f727529287b7414af6d1f482ea5f318cbd2eb.tar.xz go-tangerine-e64f727529287b7414af6d1f482ea5f318cbd2eb.tar.zst go-tangerine-e64f727529287b7414af6d1f482ea5f318cbd2eb.zip |
Merge pull request #433 from fjl/newcli
Improved CLI
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()) |