[network/libktorrent/release/26.08] src/peer: Fix sending peers with UTPex since Address writeCompact change

Jack Hill <[email protected]>
Newsgroups gmane.comp.kde.cvs
Message-ID <[email protected]>
Git commit 93d2fe14060979b0c44d04e8b8e1ddc21668c2cf by Jack Hill.
Committed on 01/08/2026 at 12:34.
Pushed by jackh into branch 'release/26.08'.

Fix sending peers with UTPex since Address writeCompact change

Amends 2f94b4cdcd8bc30218a846354887155be11c86d0


(cherry picked from commit b6ba955a742c79e90522d3f5612f77da23197104)

Co-authored-by: Jack Hill <[email protected]>

M  +1    -1    src/peer/utpex.cpp

https://invent.kde.org/network/libktorrent/-/commit/93d2fe14060979b0c44d04e8b8e1ddc21668c2cf

diff --git a/src/peer/utpex.cpp b/src/peer/utpex.cpp
index 65e3ef33..4f9f8492 100644
--- a/src/peer/utpex.cpp
+++ b/src/peer/utpex.cpp
@@ -179,7 +179,7 @@ void UTPex::encode(BEncoder &enc, const std::map<Uint32, net::Address> &ps, int
         if (addr.ipVersion() != ip_version) {
             continue;
         }
-        addr.writeCompact(tmp);
+        size += addr.writeCompact(tmp);
         tmp += compact_width;
     }
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.