use ct_memcmp

This commit is contained in:
Love Hornquist Astrand
2010-07-20 08:07:23 -07:00
parent baec3d761c
commit 94a5df1840

View File

@@ -41,6 +41,7 @@
#include <hmac.h> #include <hmac.h>
#include <evp.h> #include <evp.h>
#include <roken.h>
int int
main(int argc, char **argv) main(int argc, char **argv)
@@ -66,7 +67,7 @@ main(int argc, char **argv)
return 1; return 1;
} }
if (memcmp(hmac, answer, hmaclen) != 0) { if (ct_memcmp(hmac, answer, hmaclen) != 0) {
printf("wrong answer\n"); printf("wrong answer\n");
return 1; return 1;
} }