Skip to content

Commit

Permalink
EpochSchedule is now not copyable, clone it explicitly.
Browse files Browse the repository at this point in the history
  • Loading branch information
wen-coding authored and AshwinSekar committed Jan 3, 2024
1 parent 0967f73 commit e3dcff6
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions gossip/src/duplicate_shred_handler.rs
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ impl DuplicateShredHandler {
self.last_root = last_root;
if let Ok(bank_fork) = self.bank_forks.try_read() {
let root_bank = bank_fork.root_bank();
self.cached_epoch_schedule = Some(*root_bank.epoch_schedule());
self.cached_epoch_schedule = Some(root_bank.epoch_schedule().clone());
let epoch_info = root_bank.get_epoch_info();
self.enable_gossip_duplicate_proof_ingestion_epoch = root_bank
.feature_set
Expand Down Expand Up @@ -148,7 +148,7 @@ impl DuplicateShredHandler {
shred1.into_payload(),
shred2.into_payload(),
)?;
if let Some(epoch_schedule) = self.cached_epoch_schedule {
if let Some(epoch_schedule) = &self.cached_epoch_schedule {
// feature_epoch could only be 0 in tests and new cluster setup.
if self
.enable_gossip_duplicate_proof_ingestion_epoch
Expand Down

0 comments on commit e3dcff6

Please sign in to comment.