Browse Source

proper endiness of relay tag

pull/93/head
orignal 10 years ago
parent
commit
9655891e4b
  1. 2
      SSU.cpp

2
SSU.cpp

@ -314,7 +314,7 @@ namespace ssu @@ -314,7 +314,7 @@ namespace ssu
rnd.GenerateWord32 (relayTag);
m_Server.AddRelay (relayTag, m_RemoteEndpoint);
}
*(uint32_t *)(payload) = relayTag;
*(uint32_t *)(payload) = htobe32 (relayTag);
payload += 4; // relay tag
*(uint32_t *)(payload) = htobe32 (i2p::util::GetSecondsSinceEpoch ()); // signed on time
payload += 4;

Loading…
Cancel
Save