From 838eea61f9d41b035041c535b868db4a06a91234 Mon Sep 17 00:00:00 2001 From: debris Date: Fri, 15 Jan 2016 01:57:14 +0100 Subject: [PATCH] updated to rocksdb wrapper version 0.3 --- Cargo.toml | 2 +- src/overlaydb.rs | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/Cargo.toml b/Cargo.toml index 6e32edcab..f92dcca53 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -15,7 +15,7 @@ mio = "0.5.0" rand = "0.3.12" time = "0.1.34" tiny-keccak = "1.0" -rocksdb = "0.2" +rocksdb = "0.3" lazy_static = "0.1" eth-secp256k1 = { git = "https://github.com/arkpar/rust-secp256k1.git" } rust-crypto = "0.2.34" diff --git a/src/overlaydb.rs b/src/overlaydb.rs index 5539a8893..929a492ef 100644 --- a/src/overlaydb.rs +++ b/src/overlaydb.rs @@ -10,7 +10,7 @@ use std::ops::*; use std::sync::*; use std::env; use std::collections::HashMap; -use rocksdb::{DB, Writable}; +use rocksdb::{DB, Writable, IteratorMode}; #[derive(Clone)] /// Implementation of the HashDB trait for a disk-backed database with a memory overlay. @@ -138,7 +138,7 @@ impl OverlayDB { impl HashDB for OverlayDB { fn keys(&self) -> HashMap { let mut ret: HashMap = HashMap::new(); - for (key, _) in self.backing.iterator().from_start() { + for (key, _) in self.backing.iterator(IteratorMode::Start) { let h = H256::from_slice(key.deref()); let r = self.payload(&h).unwrap().1; ret.insert(h, r as i32);