summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAdam Ierymenko <adam.ierymenko@zerotier.com>2015-11-12 16:51:33 -0800
committerAdam Ierymenko <adam.ierymenko@zerotier.com>2015-11-12 16:51:33 -0800
commitccae473783f834c9062474f7bb347b698764c8be (patch)
tree7cb2a042ba6954af4f638faa2bfbc553c7dd19af
parent54f68280bd65589fc858901f1c5c4ed8588862c3 (diff)
downloadinfinitytier-ccae473783f834c9062474f7bb347b698764c8be.tar.gz
infinitytier-ccae473783f834c9062474f7bb347b698764c8be.zip
Eliminate Windows warnings.
-rw-r--r--node/Node.cpp4
-rw-r--r--node/Topology.cpp2
2 files changed, 3 insertions, 3 deletions
diff --git a/node/Node.cpp b/node/Node.cpp
index 31757b45..4b449401 100644
--- a/node/Node.cpp
+++ b/node/Node.cpp
@@ -203,7 +203,7 @@ public:
for(std::vector<World::Root>::const_iterator r(_world.roots().begin());r!=_world.roots().end();++r) {
if (r->identity.address() == p->address()) {
upstream = true;
- for(unsigned long k=0,ptr=RR->node->prng();k<r->stableEndpoints.size();++k) {
+ for(unsigned long k=0,ptr=(unsigned long)RR->node->prng();k<(unsigned long)r->stableEndpoints.size();++k) {
const InetAddress &addr = r->stableEndpoints[ptr++ % r->stableEndpoints.size()];
if (!stableEndpoint4) {
if (addr.ss_family == AF_INET)
@@ -536,7 +536,7 @@ ZT_ResultCode Node::circuitTestBegin(ZT_CircuitTest *test,void (*reportCallback)
outp.append((uint16_t)0);
C25519::Signature sig(RR->identity.sign(reinterpret_cast<const char *>(outp.data()) + ZT_PACKET_IDX_PAYLOAD,outp.size() - ZT_PACKET_IDX_PAYLOAD));
outp.append((uint16_t)sig.size());
- outp.append(sig.data,sig.size());
+ outp.append(sig.data,(unsigned int)sig.size());
outp.append((uint16_t)0); // originator doesn't need an extra credential, since it's the originator
for(unsigned int h=1;h<test->hopCount;++h) {
outp.append((uint8_t)0);
diff --git a/node/Topology.cpp b/node/Topology.cpp
index bea97ab9..5379ac1f 100644
--- a/node/Topology.cpp
+++ b/node/Topology.cpp
@@ -76,7 +76,7 @@ Topology::Topology(const RuntimeEnvironment *renv) :
std::string dsWorld(RR->node->dataStoreGet("world"));
World cachedWorld;
try {
- Buffer<ZT_WORLD_MAX_SERIALIZED_LENGTH> dswtmp(dsWorld.data(),dsWorld.length());
+ Buffer<ZT_WORLD_MAX_SERIALIZED_LENGTH> dswtmp(dsWorld.data(),(unsigned int)dsWorld.length());
cachedWorld.deserialize(dswtmp,0);
} catch ( ... ) {
cachedWorld = World(); // clear if cached world is invalid