Minor buig fixes
This commit is contained in:
parent
d025d957a6
commit
3e4ec00f0a
|
@ -172,7 +172,7 @@ pub fn poll_block(
|
|||
let task_spawner: AnyhowJoinHandle = tokio::spawn(async move {
|
||||
let counting_semaphore = Arc::new(tokio::sync::Semaphore::new(1024));
|
||||
let mut slot_notification = slot_notification;
|
||||
let current_slot = Arc::new(AtomicU64::new(0));
|
||||
let current_slot = Arc::new(AtomicU64::new(rpc_client.get_slot()));
|
||||
loop {
|
||||
let SlotNotification { processed_slot, .. } = slot_notification
|
||||
.recv()
|
||||
|
|
|
@ -84,13 +84,14 @@ pub fn poll_slots(
|
|||
// this is because it may be a slot block
|
||||
if estimated_slot < current_slot + 32 {
|
||||
estimated_slot += 1;
|
||||
|
||||
sender
|
||||
.send(SlotNotification {
|
||||
processed_slot: current_slot,
|
||||
estimated_processed_slot: estimated_slot,
|
||||
})
|
||||
.context("Connot send slot notification")?;
|
||||
}
|
||||
sender
|
||||
.send(SlotNotification {
|
||||
processed_slot: current_slot,
|
||||
estimated_processed_slot: estimated_slot,
|
||||
})
|
||||
.context("Connot send slot notification")?;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue