summaryrefslogtreecommitdiff
path: root/vmac.cpp
diff options
context:
space:
mode:
authorJeffrey Walton <noloader@gmail.com>2015-07-31 04:44:28 -0400
committerJeffrey Walton <noloader@gmail.com>2015-07-31 04:44:28 -0400
commitb84cd9013af00a3c909d83e6b98a7f03ea95e6c2 (patch)
tree26f86e8ff88760e9ecb12f207ca14f0b35fb78d8 /vmac.cpp
parent3caada0a9eb506bfbd54d46517d646b43a00882b (diff)
downloadcryptopp-git-b84cd9013af00a3c909d83e6b98a7f03ea95e6c2.tar.gz
Supress "-Wmaybe-unitiialized" warning under GCC; guard to ensure it does not produce unknown pragma warning under Clang
Diffstat (limited to 'vmac.cpp')
-rw-r--r--vmac.cpp14
1 files changed, 14 insertions, 0 deletions
diff --git a/vmac.cpp b/vmac.cpp
index 02603829..b15651fc 100644
--- a/vmac.cpp
+++ b/vmac.cpp
@@ -448,6 +448,16 @@ VMAC_Base::VHASH_Update_SSE2(const word64 *data, size_t blocksRemainingInWord64,
(rh) += (ih) + ((rl) < (_il)); \
}
#endif
+
+// vmac.cpp:404:93: warning: ‘al2’ may be used uninitialized in this function
+// ... vmac.cpp:479:26: note: ‘al2’ was declared here
+// Valgrind cleared this finding.
+#if GCC_DIAGNOSTIC_AWARE
+# pragma GCC diagnostic push
+# ifndef __clang__
+# pragma GCC diagnostic ignored "-Wmaybe-uninitialized"
+# endif
+#endif
#if !(defined(_MSC_VER) && _MSC_VER < 1300)
template <bool T_128BitTag>
@@ -709,6 +719,10 @@ void VMAC_Base::VHASH_Update_Template(const word64 *data, size_t blocksRemaining
#endif
}
+#if GCC_DIAGNOSTIC_AWARE
+# pragma GCC diagnostic pop
+#endif
+
inline void VMAC_Base::VHASH_Update(const word64 *data, size_t blocksRemainingInWord64)
{
#if CRYPTOPP_BOOL_SSE2_ASM_AVAILABLE && CRYPTOPP_BOOL_X86