diff options
Diffstat (limited to 'Swiften/StringCodecs')
-rw-r--r-- | Swiften/StringCodecs/Base64.cpp | 1 | ||||
-rw-r--r-- | Swiften/StringCodecs/Hexify.cpp | 2 | ||||
-rw-r--r-- | Swiften/StringCodecs/MD5.cpp | 3 | ||||
-rw-r--r-- | Swiften/StringCodecs/SHA1.cpp | 4 | ||||
-rw-r--r-- | Swiften/StringCodecs/SHA256.cpp | 3 |
5 files changed, 11 insertions, 2 deletions
diff --git a/Swiften/StringCodecs/Base64.cpp b/Swiften/StringCodecs/Base64.cpp index e4eaa4e..195987e 100644 --- a/Swiften/StringCodecs/Base64.cpp +++ b/Swiften/StringCodecs/Base64.cpp @@ -14,6 +14,7 @@ namespace Swift { #pragma GCC diagnostic ignored "-Wold-style-cast" +#pragma clang diagnostic ignored "-Wconversion" namespace { template<typename TargetType, typename SourceType> diff --git a/Swiften/StringCodecs/Hexify.cpp b/Swiften/StringCodecs/Hexify.cpp index 668079b..0e6dc4e 100644 --- a/Swiften/StringCodecs/Hexify.cpp +++ b/Swiften/StringCodecs/Hexify.cpp @@ -13,6 +13,8 @@ #include <string> #include <Swiften/Base/ByteArray.h> +#pragma clang diagnostic ignored "-Wconversion" + namespace Swift { std::string Hexify::hexify(unsigned char byte) { diff --git a/Swiften/StringCodecs/MD5.cpp b/Swiften/StringCodecs/MD5.cpp index bd03314..ffed37b 100644 --- a/Swiften/StringCodecs/MD5.cpp +++ b/Swiften/StringCodecs/MD5.cpp @@ -32,6 +32,9 @@ */ #pragma GCC diagnostic ignored "-Wold-style-cast" +#pragma clang diagnostic ignored "-Wconversion" +#pragma clang diagnostic ignored "-Wcast-align" +#pragma clang diagnostic ignored "-Wmissing-prototypes" #include <Swiften/StringCodecs/MD5.h> diff --git a/Swiften/StringCodecs/SHA1.cpp b/Swiften/StringCodecs/SHA1.cpp index e4081f4..8b03989 100644 --- a/Swiften/StringCodecs/SHA1.cpp +++ b/Swiften/StringCodecs/SHA1.cpp @@ -185,7 +185,7 @@ SHA1::SHA1() { SHA1& SHA1::update(const std::vector<unsigned char>& input) { std::vector<unsigned char> inputCopy(input); - Update(&context, (boost::uint8_t*) vecptr(inputCopy), inputCopy.size()); + Update(&context, (boost::uint8_t*) vecptr(inputCopy), static_cast<unsigned int>(inputCopy.size())); return *this; } @@ -203,7 +203,7 @@ ByteArray SHA1::getHashInternal(const Container& input) { Init(&context); Container inputCopy(input); - Update(&context, (boost::uint8_t*) vecptr(inputCopy), inputCopy.size()); + Update(&context, (boost::uint8_t*) vecptr(inputCopy), static_cast<unsigned int>(inputCopy.size())); ByteArray digest; digest.resize(20); diff --git a/Swiften/StringCodecs/SHA256.cpp b/Swiften/StringCodecs/SHA256.cpp index f92e7af..6e3c4ec 100644 --- a/Swiften/StringCodecs/SHA256.cpp +++ b/Swiften/StringCodecs/SHA256.cpp @@ -11,6 +11,9 @@ #include <string.h> #pragma GCC diagnostic ignored "-Wold-style-cast" +#pragma clang diagnostic ignored "-Wconversion" +#pragma clang diagnostic ignored "-Wunused-macros" +#pragma clang diagnostic ignored "-Wdisabled-macro-expansion" using namespace Swift; |