aboutsummaryrefslogtreecommitdiffstats
path: root/src/lib/utils/ct_utils.h
diff options
context:
space:
mode:
authorJack Lloyd <[email protected]>2016-02-17 00:17:09 -0500
committerJack Lloyd <[email protected]>2016-02-17 00:17:09 -0500
commit167d062dd9d60177691aa675a8a5b64424aa00e3 (patch)
treee34e2b28d7846ee6876277d79c82e31161048c90 /src/lib/utils/ct_utils.h
parente8700f6f6062fd769dea267646f9ac951de90a05 (diff)
Add constant time conditional swap, add, sub for bigint words
Not optimized and relies on asm support for const time word_add/word_sub instructions. Fix a bug introduced in 46e9a89 - unpoison needs to call the valgrind API with the pointer rather than the reference. Caused values not to be unpoisoned.
Diffstat (limited to 'src/lib/utils/ct_utils.h')
-rw-r--r--src/lib/utils/ct_utils.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/lib/utils/ct_utils.h b/src/lib/utils/ct_utils.h
index 3d0d1ac86..401a53e86 100644
--- a/src/lib/utils/ct_utils.h
+++ b/src/lib/utils/ct_utils.h
@@ -68,7 +68,7 @@ template<typename T>
inline void unpoison(T& p)
{
#if defined(BOTAN_HAS_VALGRIND)
- VALGRIND_MAKE_MEM_DEFINED(p, sizeof(T));
+ VALGRIND_MAKE_MEM_DEFINED(&p, sizeof(T));
#else
BOTAN_UNUSED(p);
#endif