Add a MIN_VERSION constant to zebra_network.
When we perform a handshake with a remote peer, we need to encode the version messages with a particular network version before we find out what the remote peer's version preference is. So in addition to having a CURRENT_VERSION constant (which represents our preference), we need to have a MIN_VERSION during the handshake (and later to determine whether we'll talk to the peer at all).
This commit is contained in:
parent
34c026ccca
commit
3f3889fef0
|
@ -8,6 +8,9 @@ pub const USER_AGENT: &'static str = "Zebra v2.0.0-alpha.0";
|
|||
/// The Zcash network protocol version used on mainnet.
|
||||
pub const CURRENT_VERSION: Version = Version(170_007);
|
||||
|
||||
/// The minimum version supported for peer connections.
|
||||
pub const MIN_VERSION: Version = Version(170_007);
|
||||
|
||||
/// Magic numbers used to identify different Zcash networks.
|
||||
pub mod magics {
|
||||
use super::*;
|
||||
|
|
Loading…
Reference in New Issue