From 7af1f402589ec207f8312b7d1397984d0b8f262b Mon Sep 17 00:00:00 2001 From: Asanka Herath Date: Fri, 18 Jun 2010 16:13:59 -0400 Subject: [PATCH] hcrypto/test_rand.c: Add w32crypto method Also make it non-fatal to request a method that is unsupported. This makes it possible to only test methods that we are compiling. --- lib/hcrypto/test_rand.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/lib/hcrypto/test_rand.c b/lib/hcrypto/test_rand.c index aec538f4d..dc98218d9 100644 --- a/lib/hcrypto/test_rand.c +++ b/lib/hcrypto/test_rand.c @@ -127,8 +127,12 @@ main(int argc, char **argv) else if (strcasecmp(rand_method, "egd") == 0) RAND_set_rand_method(RAND_egd_method()); #endif +#ifdef WIN32 + else if (strcasecmp(rand_method, "w32crypto") == 0) + RAND_set_rand_method(RAND_w32crypto_method()); +#endif else - errx(1, "unknown method %s", rand_method); + errx(0, "unknown method %s", rand_method); } if (RAND_file_name(path, sizeof(path)) == NULL) -- 2.11.4.GIT