mirror of
https://github.com/jwinterm/grin-wallet.git
synced 2026-10-29 20:18:41 +01:00
updates based on upstream
This commit is contained in:
@@ -13,7 +13,6 @@
|
||||
// limitations under the License.
|
||||
|
||||
use std::cell::RefCell;
|
||||
use std::sync::Arc;
|
||||
use std::{fs, path};
|
||||
|
||||
// for writing storedtransaction files
|
||||
@@ -112,8 +111,7 @@ impl<C, K> LMDBBackend<C, K> {
|
||||
fs::create_dir_all(&stored_tx_path)
|
||||
.expect("Couldn't create wallet backend tx storage directory!");
|
||||
|
||||
let lmdb_env = Arc::new(store::new_env(db_path.to_str().unwrap().to_string()));
|
||||
let store = store::Store::open(lmdb_env, DB_DIR);
|
||||
let store = store::Store::new(db_path.to_str().unwrap(), Some(DB_DIR), None)?;
|
||||
|
||||
// Make sure default wallet derivation path always exists
|
||||
// as well as path (so it can be retrieved by batches to know where to store
|
||||
|
||||
@@ -34,7 +34,6 @@ use grin_api as api;
|
||||
use grin_chain as chain;
|
||||
use grin_core as core;
|
||||
use grin_keychain as keychain;
|
||||
use grin_store as store;
|
||||
use grin_util as util;
|
||||
use serde_json;
|
||||
use std::collections::HashMap;
|
||||
@@ -101,10 +100,8 @@ where
|
||||
let genesis_block = pow::mine_genesis_block().unwrap();
|
||||
let verifier_cache = Arc::new(RwLock::new(LruVerifierCache::new()));
|
||||
let dir_name = format!("{}/.grin", chain_dir);
|
||||
let db_env = Arc::new(store::new_env(dir_name.to_string()));
|
||||
let c = Chain::init(
|
||||
dir_name.to_string(),
|
||||
db_env,
|
||||
Arc::new(NoopAdapter {}),
|
||||
genesis_block,
|
||||
pow::verify_size,
|
||||
|
||||
Reference in New Issue
Block a user