Skip to content

Instantly share code, notes, and snippets.

@eisterman
Created October 27, 2019 22:44
Show Gist options
  • Save eisterman/b21f45295605a70aa165183a221e4694 to your computer and use it in GitHub Desktop.
Save eisterman/b21f45295605a70aa165183a221e4694 to your computer and use it in GitHub Desktop.
Funzione Multithread "monca" NameChain
fn get_last_block(bc_file: &Arc<Mutex<File>>) -> io::Result<String> {
let mut f = bc_file.lock().unwrap();
let a = BufReader::new(f.deref_mut()).lines();
a.last().unwrap()
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment