Skip to content

Commit

Permalink
firedancer: send genesis hash message
Browse files Browse the repository at this point in the history
  • Loading branch information
jherrera-jump committed Jan 28, 2025
1 parent c39c1d0 commit 4d931a6
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions validator/src/bootstrap.rs
Original file line number Diff line number Diff line change
Expand Up @@ -409,6 +409,16 @@ pub fn attempt_download_genesis_and_snapshot(
rpc_client,
)?;

let mut memory: [u8; 32] = [0; 32];
memory[0..32].copy_from_slice(&validator_config.expected_genesis_hash.unwrap().to_bytes());

extern "C" {
fn fd_ext_plugin_publish_genesis_hash(kind: u8, data: *const u8, len: u64);
}
unsafe {
fd_ext_plugin_publish_genesis_hash(13, memory.as_ptr(), 32);
}

if let Some(gossip) = gossip.take() {
shutdown_gossip_service(gossip);
}
Expand Down

0 comments on commit 4d931a6

Please sign in to comment.