From 94a07b05cc812ec7580cb87b481f2719ac61ae7c Mon Sep 17 00:00:00 2001 From: Henry de Valence Date: Wed, 25 Sep 2019 09:00:04 -0700 Subject: [PATCH] Move HEADER_LEN constant to top of file. --- zebra-network/src/protocol/codec.rs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/zebra-network/src/protocol/codec.rs b/zebra-network/src/protocol/codec.rs index 87e57824c..8ceb58f8a 100644 --- a/zebra-network/src/protocol/codec.rs +++ b/zebra-network/src/protocol/codec.rs @@ -17,6 +17,9 @@ use crate::{constants, types::*, Network}; use super::message::Message; +/// The length of a Bitcoin message header. +const HEADER_LEN: usize = 24usize; + /// A codec which produces Bitcoin messages from byte streams and vice versa. pub struct Codec { builder: Builder, @@ -89,9 +92,6 @@ impl Builder { } } -/// The length of a Bitcoin message header. -const HEADER_LEN: usize = 24usize; - // ======== Encoding ========= impl Codec {