Handle wrapped PublicKey struct

This commit is contained in:
Tyera Eulberg
2018-07-31 11:27:08 -06:00
committed by Grimes
parent a86618faf3
commit cf70e5ff2f
5 changed files with 12 additions and 9 deletions

View File

@@ -135,7 +135,8 @@ pub struct NodeInfo {
pub ledger_state: LedgerState,
}
fn make_debug_id(buf: &[u8]) -> u64 {
fn make_debug_id(key: &PublicKey) -> u64 {
let buf: &[u8] = &key.0;
let mut rdr = Cursor::new(&buf[..8]);
rdr.read_u64::<LittleEndian>()
.expect("rdr.read_u64 in fn debug_id")