network: use full 32-bits of transaction IDs

We used to use the first 16 bits for the message type.
This commit is contained in:
Adrien Béraud committed 2017-10-20 17:42:28 +02:00
1 parent 4501217c21
commit 476fbb1160
12 files changed
+151 -180

No files matched your search

-15
View File
@@ -19,7 +19,6 @@
#include "utils.h"
#include "sockaddr.h"
#include "default_types.h"
#include "net.h"
/* An IPv4 equivalent to IN6_IS_ADDR_UNSPECIFIED */
#ifndef IN_IS_ADDR_UNSPECIFIED
@@ -161,18 +160,4 @@ findMapValue(msgpack::object& map, const std::string& key) {
return nullptr;
}
namespace net {
TransId
unpackTid(msgpack::object& o) {
switch (o.type) {
case msgpack::type::POSITIVE_INTEGER:
return o.as<uint32_t>();
default:
return o.as<std::array<char, 4>>();
}
}
}
}