aboutsummaryrefslogtreecommitdiff
path: root/src/message.cpp
diff options
context:
space:
mode:
authorMark Haines <mark.haines@matrix.org>2015-06-12 14:09:41 +0100
committerMark Haines <mark.haines@matrix.org>2015-06-12 14:09:41 +0100
commit6ecea67718803e96e00a18f97ae8abc83ecaa1c2 (patch)
tree41de34500c1dfa104b791606a67b6bcf84a14ed9 /src/message.cpp
parent08a7e44a966047a10d7e959d4a8cdeaaf4139ce0 (diff)
Implement the session key exchange
Diffstat (limited to 'src/message.cpp')
-rw-r--r--src/message.cpp14
1 files changed, 7 insertions, 7 deletions
diff --git a/src/message.cpp b/src/message.cpp
index fcedd07..d9978cb 100644
--- a/src/message.cpp
+++ b/src/message.cpp
@@ -198,15 +198,15 @@ void axolotl::decode_message(
) {
std::uint8_t const * pos = input;
std::uint8_t const * end = input + input_length - mac_length;
- std::uint8_t const * unknown = NULL;
+ std::uint8_t const * unknown = nullptr;
if (pos == end) return;
reader.version = *(pos++);
reader.input = input;
reader.input_length = input_length;
reader.has_counter = false;
- reader.ratchet_key = NULL;
- reader.ciphertext = NULL;
+ reader.ratchet_key = nullptr;
+ reader.ciphertext = nullptr;
while (pos != end) {
pos = decode(
@@ -283,15 +283,15 @@ void axolotl::decode_one_time_key_message(
) {
std::uint8_t const * pos = input;
std::uint8_t const * end = input + input_length;
- std::uint8_t const * unknown = NULL;
+ std::uint8_t const * unknown = nullptr;
if (pos == end) return;
reader.version = *(pos++);
reader.has_registration_id = false;
reader.has_one_time_key_id = false;
- reader.identity_key = NULL;
- reader.base_key = NULL;
- reader.message = NULL;
+ reader.identity_key = nullptr;
+ reader.base_key = nullptr;
+ reader.message = nullptr;
while (pos != end) {
pos = decode(