aboutsummaryrefslogtreecommitdiff
path: root/tests/test_base64.cpp
diff options
context:
space:
mode:
authorRichard van der Hoff <richard@matrix.org>2016-05-20 11:59:31 +0100
committerRichard van der Hoff <richard@matrix.org>2016-05-23 18:55:06 +0100
commit444ef1f70687c340ba1b0b2a22d6e63c734d5f9e (patch)
tree08e39a888a262acab58d2c0616a966a5e1034ca1 /tests/test_base64.cpp
parentc57b2b71c5a1314e79a0ee110ed9e1168a70b921 (diff)
Prefix for internal symbols
Give a load of internal symbols "_olm_" prefixes. This better delineates the public and private interfaces in the module, and helps avoid internal symbols leaking out and possibly being abused.
Diffstat (limited to 'tests/test_base64.cpp')
-rw-r--r--tests/test_base64.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/tests/test_base64.cpp b/tests/test_base64.cpp
index a1efe17..c95e3c9 100644
--- a/tests/test_base64.cpp
+++ b/tests/test_base64.cpp
@@ -26,11 +26,11 @@ std::uint8_t input[] = "Hello World";
std::uint8_t expected_output[] = "SGVsbG8gV29ybGQ";
std::size_t input_length = sizeof(input) - 1;
-std::size_t output_length = ::olm_encode_base64_length(input_length);
+std::size_t output_length = ::_olm_encode_base64_length(input_length);
assert_equals(std::size_t(15), output_length);
std::uint8_t output[output_length];
-output_length = ::olm_encode_base64(input, input_length, output);
+output_length = ::_olm_encode_base64(input, input_length, output);
assert_equals(std::size_t(15), output_length);
assert_equals(expected_output, output, output_length);
}
@@ -57,11 +57,11 @@ std::uint8_t input[] = "SGVsbG8gV29ybGQ";
std::uint8_t expected_output[] = "Hello World";
std::size_t input_length = sizeof(input) - 1;
-std::size_t output_length = ::olm_decode_base64_length(input_length);
+std::size_t output_length = ::_olm_decode_base64_length(input_length);
assert_equals(std::size_t(11), output_length);
std::uint8_t output[output_length];
-output_length = ::olm_decode_base64(input, input_length, output);
+output_length = ::_olm_decode_base64(input, input_length, output);
assert_equals(std::size_t(11), output_length);
assert_equals(expected_output, output, output_length);
}