mirror of
https://github.com/hoytech/strfry.git
synced 2025-06-19 17:37:43 +00:00
use negentropy protocol 0
This commit is contained in:
@ -134,7 +134,13 @@ void cmd_sync(const std::vector<std::string> &subArgs) {
|
||||
if (!doUp) have.clear();
|
||||
if (!doDown) need.clear();
|
||||
|
||||
if (neMsg.size() == 0) {
|
||||
if (neMsg) {
|
||||
ws.send(tao::json::to_string(tao::json::value::array({
|
||||
"NEG-MSG",
|
||||
"N",
|
||||
to_hex(*neMsg),
|
||||
})));
|
||||
} else {
|
||||
syncDone = true;
|
||||
LI << "Set reconcile complete. Have " << totalHaves << " need " << totalNeeds;
|
||||
|
||||
@ -142,12 +148,6 @@ void cmd_sync(const std::vector<std::string> &subArgs) {
|
||||
"NEG-CLOSE",
|
||||
"N",
|
||||
})));
|
||||
} else {
|
||||
ws.send(tao::json::to_string(tao::json::value::array({
|
||||
"NEG-MSG",
|
||||
"N",
|
||||
to_hex(neMsg),
|
||||
})));
|
||||
}
|
||||
} else if (msg.at(0) == "OK") {
|
||||
inFlightUp--;
|
||||
|
Reference in New Issue
Block a user