Send votes to next leader's TPU instead of our TPU (#16663)
(cherry picked from commit c8b474cd0b)
Co-authored-by: Michael Vines <mvines@gmail.com>
This commit is contained in:
@@ -1183,8 +1183,8 @@ impl ClusterInfo {
|
||||
.process_push_message(&self_pubkey, vec![vote], now);
|
||||
}
|
||||
|
||||
pub fn send_vote(&self, vote: &Transaction) -> Result<()> {
|
||||
let tpu = self.my_contact_info().tpu;
|
||||
pub fn send_vote(&self, vote: &Transaction, tpu: Option<SocketAddr>) -> Result<()> {
|
||||
let tpu = tpu.unwrap_or_else(|| self.my_contact_info().tpu);
|
||||
let buf = serialize(vote)?;
|
||||
self.socket.send_to(&buf, &tpu)?;
|
||||
Ok(())
|
||||
|
||||
Reference in New Issue
Block a user