Remove flushln!s.
This commit is contained in:
parent
387e3ec3fd
commit
50d1038cc5
@ -145,7 +145,6 @@ impl Client {
|
||||
/// Create a new client with given spec and DB path.
|
||||
pub fn new(spec: Spec, path: &Path, message_channel: IoChannel<NetSyncMessage> ) -> Result<Arc<Client>, Error> {
|
||||
let gb = spec.genesis_block();
|
||||
flushln!("Spec says genesis block is {}", gb.pretty());
|
||||
let chain = Arc::new(RwLock::new(BlockChain::new(&gb, path)));
|
||||
let mut opts = Options::new();
|
||||
opts.set_max_open_files(256);
|
||||
@ -177,7 +176,7 @@ impl Client {
|
||||
if engine.spec().ensure_db_good(&mut state_db) {
|
||||
state_db.commit(0, &engine.spec().genesis_header().hash(), None).expect("Error commiting genesis state to state DB");
|
||||
}
|
||||
flushln!("Client::new: commiting. Best root now: {}. contains: {}", chain.read().unwrap().genesis_header().state_root, state_db.contains(&chain.read().unwrap().genesis_header().state_root));
|
||||
trace!("Client::new: commiting. Best root now: {}. contains: {}", chain.read().unwrap().genesis_header().state_root, state_db.contains(&chain.read().unwrap().genesis_header().state_root));
|
||||
Ok(Arc::new(Client {
|
||||
chain: chain,
|
||||
engine: engine.clone(),
|
||||
|
@ -275,8 +275,6 @@ impl evm::Evm for Interpreter {
|
||||
code: &code
|
||||
};
|
||||
|
||||
flushln!("Executing: {:?}", params);
|
||||
|
||||
while reader.position < code.len() {
|
||||
let instruction = code[reader.position];
|
||||
reader.position += 1;
|
||||
@ -642,7 +640,6 @@ impl Interpreter {
|
||||
return Ok(InstructionResult::StopExecution);
|
||||
},
|
||||
instructions::SUICIDE => {
|
||||
flushln!("SUICIDE!");
|
||||
let address = stack.pop_back();
|
||||
ext.suicide(&u256_to_address(&address));
|
||||
return Ok(InstructionResult::StopExecution);
|
||||
|
@ -173,7 +173,7 @@ impl<'a> Executive<'a> {
|
||||
if let ActionValue::Transfer(val) = params.value {
|
||||
self.state.transfer_balance(¶ms.sender, ¶ms.address, &val);
|
||||
}
|
||||
flushln!("Executive::call(params={:?}) self.env_info={:?}", params, self.info);
|
||||
trace!("Executive::call(params={:?}) self.env_info={:?}", params, self.info);
|
||||
|
||||
if self.engine.is_builtin(¶ms.code_address) {
|
||||
// if destination is builtin, try to execute it
|
||||
@ -260,17 +260,16 @@ impl<'a> Executive<'a> {
|
||||
let refund_value = gas_left * t.gas_price;
|
||||
let fees_value = gas_used * t.gas_price;
|
||||
|
||||
flushln!("exec::finalize: t.gas={}, sstore_refunds={}, suicide_refunds={}, refunds_bound={}, gas_left_prerefund={}, refunded={}, gas_left={}, gas_used={}, refund_value={}, fees_value={}\n",
|
||||
trace!("exec::finalize: t.gas={}, sstore_refunds={}, suicide_refunds={}, refunds_bound={}, gas_left_prerefund={}, refunded={}, gas_left={}, gas_used={}, refund_value={}, fees_value={}\n",
|
||||
t.gas, sstore_refunds, suicide_refunds, refunds_bound, gas_left_prerefund, refunded, gas_left, gas_used, refund_value, fees_value);
|
||||
|
||||
flushln!("exec::finalize: Refunding refund_value={}, sender={}\n", refund_value, t.sender().unwrap());
|
||||
trace!("exec::finalize: Refunding refund_value={}, sender={}\n", refund_value, t.sender().unwrap());
|
||||
self.state.add_balance(&t.sender().unwrap(), &refund_value);
|
||||
flushln!("exec::finalize: Compensating author: fees_value={}, author={}\n", fees_value, &self.info.author);
|
||||
trace!("exec::finalize: Compensating author: fees_value={}, author={}\n", fees_value, &self.info.author);
|
||||
self.state.add_balance(&self.info.author, &fees_value);
|
||||
|
||||
// perform suicides
|
||||
for address in &substate.suicides {
|
||||
flushln!("Killing {}", address);
|
||||
self.state.kill_account(address);
|
||||
}
|
||||
|
||||
|
@ -215,7 +215,7 @@ impl<'a> Ext for Externalities<'a> {
|
||||
fn suicide(&mut self, refund_address: &Address) {
|
||||
let address = self.origin_info.address.clone();
|
||||
let balance = self.balance(&address);
|
||||
flushln!("Suiciding {} -> {} (xfer: {})", address, refund_address, balance);
|
||||
trace!("Suiciding {} -> {} (xfer: {})", address, refund_address, balance);
|
||||
self.state.transfer_balance(&address, refund_address, &balance);
|
||||
self.substate.suicides.insert(address);
|
||||
}
|
||||
|
@ -103,7 +103,6 @@ impl State {
|
||||
|
||||
/// Mutate storage of account `a` so that it is `value` for `key`.
|
||||
pub fn code(&self, a: &Address) -> Option<Bytes> {
|
||||
flushln!("Getting code at {}", a);
|
||||
self.get(a, true).as_ref().map_or(None, |a|a.code().map(|x|x.to_vec()))
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user