mirror of
https://github.com/twisterarmy/twister-core.git
synced 2025-01-09 14:28:22 +00:00
revert tracker dhtget patch of 0.9.16 and report number of peers received
This commit is contained in:
parent
36cf59c705
commit
a542ad81e7
@ -132,10 +132,13 @@ void dht_get_observer::reply(msg const& m)
|
|||||||
// pretend it is a normal dht resource to the caller
|
// pretend it is a normal dht resource to the caller
|
||||||
dht_get *dget( static_cast<dht_get*>(m_algorithm.get()) );
|
dht_get *dget( static_cast<dht_get*>(m_algorithm.get()) );
|
||||||
if( dget->m_targetResource == "tracker" && dget->m_multi ) {
|
if( dget->m_targetResource == "tracker" && dget->m_multi ) {
|
||||||
const lazy_entry *followers = r->dict_find("followers");
|
int followers = r->dict_find_int_value("followers");
|
||||||
if( followers ) {
|
if( followers ) {
|
||||||
entry::dictionary_type v;
|
entry::dictionary_type v;
|
||||||
v["followers"] = followers->int_value();
|
v["followers"] = followers;
|
||||||
|
const lazy_entry *values = r->dict_find_list("values");
|
||||||
|
if( values )
|
||||||
|
v["values_size"] = values->list_size();
|
||||||
|
|
||||||
entry::dictionary_type target;
|
entry::dictionary_type target;
|
||||||
target["n"] = dget->m_targetUser;
|
target["n"] = dget->m_targetUser;
|
||||||
|
Loading…
Reference in New Issue
Block a user