#ifdef TEST_RIG
+#include <mLib/macros.h>
#include <mLib/testrig.h>
#include "ct.h"
poly1305_hash(&ctx, v[2].buf + j, v[2].len - j);
poly1305_done(&ctx, t.buf);
ct_remedy(t.buf, t.len);
- if (memcmp(t.buf, v[3].buf, 16) != 0) {
+ if (MEMCMP(t.buf, !=, v[3].buf, 16)) {
fprintf(stderr, "failed...");
fprintf(stderr, "\n\tkey = "); type_hex.dump(&v[0], stderr);
fprintf(stderr, "\n\tmask = "); type_hex.dump(&v[1], stderr);
poly1305_concat(&ctx, &ctx, &cc[2]);
}
poly1305_done(&ctx, t.buf);
- if (memcmp(t.buf, v[5].buf, 16) != 0) {
+ if (MEMCMP(t.buf, !=, v[5].buf, 16)) {
fprintf(stderr, "failed...");
fprintf(stderr, "\n\tkey = "); type_hex.dump(&v[0], stderr);
fprintf(stderr, "\n\tmask = "); type_hex.dump(&v[1], stderr);
}
}
- if (memcmp(t, v[4].buf, 16) != 0) {
+ if (MEMCMP(t, !=, v[4].buf, 16)) {
ok = 0;
fprintf(stderr, "failed...");
fprintf(stderr, "\n\tinitial k = "); type_hex.dump(&v[0], stderr);