mirror of
https://github.com/savoirfairelinux/opendht.git
synced 2026-11-08 04:21:51 +00:00
dht: avoid building oversized UDP packets
This commit is contained in:
1 parent
9ee962bd21
commit
3ee22bb6d7
1 file changed
+1
-1
+1
-1
@@ -3080,7 +3080,7 @@ Dht::sendNodesValues(const sockaddr *sa, socklen_t salen, TransId tid,
|
||||
pk.pack(*st[j].data);
|
||||
k++;
|
||||
j = (j + 1) % st.size();
|
||||
} while (j != j0 && k < 50);
|
||||
} while (j != j0 && k < 50 && buffer.size() < MAX_VALUE_SIZE);
|
||||
}
|
||||
|
||||
pk.pack(std::string("t")); pk.pack_bin(tid.size());
|
||||
|
||||
Reference in new issue
Block a user