diff options
Diffstat (limited to 'src/utils')
-rw-r--r-- | src/utils/base64.cpp | 7 | ||||
-rw-r--r-- | src/utils/base64.hpp | 4 |
2 files changed, 6 insertions, 5 deletions
diff --git a/src/utils/base64.cpp b/src/utils/base64.cpp index 350e2db..c0959bb 100644 --- a/src/utils/base64.cpp +++ b/src/utils/base64.cpp @@ -2,18 +2,15 @@ #ifdef BOTAN_FOUND #include <botan/base64.h> -#endif namespace base64 { std::string encode(const std::string &input) { -#ifdef BOTAN_FOUND return Botan::base64_encode(reinterpret_cast<const uint8_t*>(input.data()), input.size()); -#else -#error "base64::encode() not yet implemented without Botan." -#endif } } + +#endif diff --git a/src/utils/base64.hpp b/src/utils/base64.hpp index 1dd4a4d..7c08d82 100644 --- a/src/utils/base64.hpp +++ b/src/utils/base64.hpp @@ -2,9 +2,13 @@ #include "biboumi.h" +#ifdef BOTAN_FOUND + #include <string> namespace base64 { std::string encode(const std::string& input); } + +#endif |