Skip to content

Commit ff0ab22

Browse files
authored
Merge pull request libbitcoin#948 from evoskuil/master
Add logging to electrum handshake, set buffer hint.
2 parents c4d116f + b1820fd commit ff0ab22

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

src/protocols/protocol_electrum.cpp

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -244,6 +244,7 @@ void protocol_electrum::handle_server_ping(const code& ec,
244244
send_code(error::not_implemented);
245245
}
246246

247+
// TODO: move to handshake protocol.
247248
// TODO: strip extraneous args before dispatch.
248249
// Changed in version 1.6: server must tolerate and ignore extraneous args.
249250
void protocol_electrum::handle_server_version(const code& ec,
@@ -268,7 +269,7 @@ void protocol_electrum::handle_server_version(const code& ec,
268269
{ string_t{ get_server() } },
269270
{ string_t{ get_version() } }
270271
}
271-
}, 100);
272+
}, 70);
272273
}
273274

274275
// Handlers (mempool).
@@ -348,6 +349,9 @@ bool protocol_electrum::set_version(const value_t& version) NOEXCEPT
348349
if (lower > upper)
349350
return false;
350351

352+
LOGA("Electrum [" << authority() << "] version ("
353+
<< version_to_string(client_max) << ") " << get_client());
354+
351355
version_ = upper;
352356
return true;
353357
}

0 commit comments

Comments
 (0)