1
mirror of https://github.com/jedisct1/libsodium.git synced 2024-12-19 10:05:05 -07:00

Add memory clobber

Fixes #965
This commit is contained in:
Frank Denis 2020-05-30 23:21:17 +02:00
parent 8360706c21
commit 3c49e89c19

View File

@ -132,7 +132,7 @@ fe25519_cmov(fe25519 f, const fe25519 g, unsigned int b)
"movq %[t1], 32(%[a])\n"
: [ t0 ] "=&r"(t0), [ t1 ] "=&r"(t1), [ t2 ] "=&r"(t2)
: [ a ] "r"(f), [ b ] "r"(g), [ c ] "r"(b)
: "cc");
: "cc", "memory");
#else
uint64_t mask = (uint64_t) (-(int64_t) b);
uint64_t f0, f1, f2, f3, f4;