From 0d40d1abaade83fe48ea6ea8d0615bf2cc0bb3c7 Mon Sep 17 00:00:00 2001 From: Green Sky Date: Mon, 15 Apr 2024 11:48:17 +0200 Subject: [PATCH] dont request from self --- solanaceae/ngc_ft1_sha1/sha1_ngcft1.cpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/solanaceae/ngc_ft1_sha1/sha1_ngcft1.cpp b/solanaceae/ngc_ft1_sha1/sha1_ngcft1.cpp index 0ce4b6a..d78c315 100644 --- a/solanaceae/ngc_ft1_sha1/sha1_ngcft1.cpp +++ b/solanaceae/ngc_ft1_sha1/sha1_ngcft1.cpp @@ -219,6 +219,10 @@ std::optional> SHA1_NGCFT1::selectPeerForRequest(C continue; } + if (_cr.all_of(child)) { + continue; // skip self + } + if (_cr.all_of(child)) { const auto& tgpe = _cr.get(child); un_tox_peers.push_back(tgpe.peer_number);