From e496b2e391d0ec4504ea752dea21f68132f44f7f Mon Sep 17 00:00:00 2001 From: "Wladimir J. van der Laan" Date: Fri, 29 Jul 2016 17:42:12 +0200 Subject: [PATCH 1/2] net: Ignore `notfound` P2P messages --- src/main.cpp | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/src/main.cpp b/src/main.cpp index 2b09a50d6..395bae377 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -5082,8 +5082,12 @@ bool static ProcessMessage(CNode* pfrom, string strCommand, CDataStream& vRecv, } } - else - { + else if (strCommand == NetMsgType::NOTFOUND) { + // We do not care about the NOTFOUND message, but logging an Unknown Command + // message would be undesirable as we transmit it ourselves. + } + + else { // Ignore unknown commands for extensibility LogPrint("net", "Unknown command \"%s\" from peer=%d\n", SanitizeString(strCommand), pfrom->id); } From 432bc22ade4a9aa791df2f66963a3b27e597c858 Mon Sep 17 00:00:00 2001 From: Simon Date: Sat, 22 Oct 2016 09:49:35 -0700 Subject: [PATCH 2/2] Patch backport of upstream 1588 as we don't (yet) use the NetMsgType namespace --- src/main.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main.cpp b/src/main.cpp index 395bae377..a6f6cb00c 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -5082,7 +5082,7 @@ bool static ProcessMessage(CNode* pfrom, string strCommand, CDataStream& vRecv, } } - else if (strCommand == NetMsgType::NOTFOUND) { + else if (strCommand == "notfound") { // We do not care about the NOTFOUND message, but logging an Unknown Command // message would be undesirable as we transmit it ourselves. }