From dcdc42e7356a0ae7c4d16728c8afff51f76f4546 Mon Sep 17 00:00:00 2001 From: mdw Date: Sun, 29 Apr 2001 17:39:15 +0000 Subject: [PATCH] Removed `-sched' tests. Reorganized so that we can theoretically have multiple tests in the same file. (This isn't so useful in production, but it's handy when doing test builds.) --- blkc.h | 21 +++++++++++++++------ 1 file changed, 15 insertions(+), 6 deletions(-) diff --git a/blkc.h b/blkc.h index 1debf54..6e1ea0a 100644 --- a/blkc.h +++ b/blkc.h @@ -1,6 +1,6 @@ /* -*-c-*- * - * $Id: blkc.h,v 1.3 2000/06/17 10:47:06 mdw Exp $ + * $Id: blkc.h,v 1.4 2001/04/29 17:39:15 mdw Exp $ * * Common definitions for block ciphers * @@ -30,6 +30,11 @@ /*----- Revision history --------------------------------------------------* * * $Log: blkc.h,v $ + * Revision 1.4 2001/04/29 17:39:15 mdw + * Removed `-sched' tests. Reorganized so that we can theoretically have + * multiple tests in the same file. (This isn't so useful in production, + * but it's handy when doing test builds.) + * * Revision 1.3 2000/06/17 10:47:06 mdw * Slight support for 96-bit ciphers. Support for counter-mode ciphers. * @@ -252,9 +257,9 @@ #include #include -#define BLKC_TEST(PRE, pre) \ +#define BLKC_VERIFY(PRE, pre) \ \ -static int verify(dstr *v) \ +static int pre##_verify(dstr *v) \ { \ pre##_ctx k; \ uint32 p[PRE##_BLKSZ / 4]; \ @@ -306,11 +311,14 @@ static int verify(dstr *v) \ /* --- Return --- */ \ \ return (ok); \ -} \ +} + +#define BLKC_TEST(PRE, pre) \ + \ +BLKC_VERIFY(PRE, pre) \ \ static test_chunk defs[] = { \ - { #pre, verify, { &type_hex, &type_hex, &type_hex, 0 } }, \ - { #pre "-sched", verify, { &type_hex, &type_hex, &type_hex, 0 } }, \ + { #pre, pre##_verify, { &type_hex, &type_hex, &type_hex, 0 } }, \ { 0, 0, { 0 } } \ }; \ \ @@ -321,6 +329,7 @@ int main(int argc, char *argv[]) \ } #else +# define BLKC_VERIFY(PRE, pre) # define BLKC_TEST(PRE, pre) #endif -- 2.11.0