Fix bug in Via Padlock support
diff --git a/ChangeLog b/ChangeLog
index 353b262..a8758f6 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -25,6 +25,7 @@
errors on use of deprecated functions.
Bugfix
+ * Fix bug in Via Padlock support (found by Nikos Mavrogiannopoulos).
* Fix thread safety bug in RSA operations (found by Fredrik Axelsson).
* Fix hardclock() (only used in the benchmarking program) with some
versions of mingw64 (found by kxjhlele).
diff --git a/library/padlock.c b/library/padlock.c
index f4d95fd..d83f76c 100644
--- a/library/padlock.c
+++ b/library/padlock.c
@@ -104,7 +104,7 @@
"movl %1, %%ebx \n\t"
: "=m" (ebx)
: "m" (ebx), "m" (ctrl), "m" (rk), "m" (blk)
- : "ecx", "edx", "esi", "edi" );
+ : "memory", "ecx", "edx", "esi", "edi" );
memcpy( output, blk, 16 );
@@ -155,7 +155,7 @@
: "=m" (ebx)
: "m" (ebx), "m" (count), "m" (ctrl),
"m" (rk), "m" (input), "m" (output), "m" (iw)
- : "eax", "ecx", "edx", "esi", "edi" );
+ : "memory", "eax", "ecx", "edx", "esi", "edi" );
memcpy( iv, iw, 16 );