From cd5673bdbd8bc50ba0149249f214c6ee6efcd99f Mon Sep 17 00:00:00 2001 From: Aaron Campbell Date: Fri, 16 Aug 2019 21:45:17 -0400 Subject: [PATCH] wire: Fix a few messageError string copy/paste errors. --- wire/msgcfilter.go | 2 +- wire/msggetcfheaders.go | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/wire/msgcfilter.go b/wire/msgcfilter.go index 581f5d0921..f2d95715a7 100644 --- a/wire/msgcfilter.go +++ b/wire/msgcfilter.go @@ -61,7 +61,7 @@ func (msg *MsgCFilter) BtcEncode(w io.Writer, pver uint32) error { if pver < NodeCFVersion { str := fmt.Sprintf("cfilter message invalid for protocol "+ "version %d", pver) - return messageError("MsgCFHeaders.BtcEncode", str) + return messageError("MsgCFilter.BtcEncode", str) } size := len(msg.Data) diff --git a/wire/msggetcfheaders.go b/wire/msggetcfheaders.go index eb17e7e5c0..2e3a3f6f42 100644 --- a/wire/msggetcfheaders.go +++ b/wire/msggetcfheaders.go @@ -40,7 +40,7 @@ func (msg *MsgGetCFHeaders) BtcDecode(r io.Reader, pver uint32) error { if pver < NodeCFVersion { str := fmt.Sprintf("getcfheaders message invalid for protocol "+ "version %d", pver) - return messageError("MsgCFHeaders.BtcDecode", str) + return messageError("MsgGetCFHeaders.BtcDecode", str) } // Read num block locator hashes and limit to max. @@ -51,7 +51,7 @@ func (msg *MsgGetCFHeaders) BtcDecode(r io.Reader, pver uint32) error { if count > MaxBlockLocatorsPerMsg { str := fmt.Sprintf("too many block locator hashes for message "+ "[count %v, max %v]", count, MaxBlockLocatorsPerMsg) - return messageError("MsgGetHeaders.BtcDecode", str) + return messageError("MsgGetCFHeaders.BtcDecode", str) } // Create a contiguous slice of hashes to deserialize into in order to @@ -81,7 +81,7 @@ func (msg *MsgGetCFHeaders) BtcEncode(w io.Writer, pver uint32) error { if pver < NodeCFVersion { str := fmt.Sprintf("getcfheaders message invalid for protocol "+ "version %d", pver) - return messageError("MsgCFHeaders.BtcEncode", str) + return messageError("MsgGetCFHeaders.BtcEncode", str) } // Limit to max block locator hashes per message. @@ -89,7 +89,7 @@ func (msg *MsgGetCFHeaders) BtcEncode(w io.Writer, pver uint32) error { if count > MaxBlockLocatorsPerMsg { str := fmt.Sprintf("too many block locator hashes for message "+ "[count %v, max %v]", count, MaxBlockLocatorsPerMsg) - return messageError("MsgGetHeaders.BtcEncode", str) + return messageError("MsgGetCFHeaders.BtcEncode", str) } err := WriteVarInt(w, pver, uint64(count))