X-Git-Url: https://git.openssl.org/?a=blobdiff_plain;f=test%2Frdrand_sanitytest.c;h=0e67b377bd4d2c130f3aa44ada2cac49ae0ec0d2;hb=3d362f190306b62a17aa2fd475b2bc8b3faa8142;hp=21d5139f2bc89e339d92c9854fc4a4a4638aebb1;hpb=082193ef2b25cf16ec51af9dc9f0ee890beb38b9;p=openssl.git diff --git a/test/rdrand_sanitytest.c b/test/rdrand_sanitytest.c index 21d5139f2b..0e67b377bd 100644 --- a/test/rdrand_sanitytest.c +++ b/test/rdrand_sanitytest.c @@ -1,5 +1,5 @@ /* - * Copyright 2018-2018 The OpenSSL Project Authors. All Rights Reserved. + * Copyright 2018 The OpenSSL Project Authors. All Rights Reserved. * * Licensed under the OpenSSL license (the "License"). You may not use * this file except in compliance with the License. You can obtain a copy @@ -20,7 +20,7 @@ size_t OPENSSL_ia32_rdrand_bytes(unsigned char *buf, size_t len); size_t OPENSSL_ia32_rdseed_bytes(unsigned char *buf, size_t len); -void OPENSSL_cpuid_setup(); +void OPENSSL_cpuid_setup(void); extern unsigned int OPENSSL_ia32cap_P[4]; @@ -81,12 +81,12 @@ end: return testresult; } -static int sanity_check_rdrand_bytes() +static int sanity_check_rdrand_bytes(void) { return sanity_check_bytes(OPENSSL_ia32_rdrand_bytes, 1000, 0, 10, 10); } -static int sanity_check_rdseed_bytes() +static int sanity_check_rdseed_bytes(void) { /*- * RDSEED may take many retries to succeed; note that this is effectively @@ -97,7 +97,8 @@ static int sanity_check_rdseed_bytes() return sanity_check_bytes(OPENSSL_ia32_rdseed_bytes, 1000, 1, 10000, 10); } -int setup_tests() { +int setup_tests(void) +{ OPENSSL_cpuid_setup(); int have_rdseed = (OPENSSL_ia32cap_P[2] & (1 << 18)) != 0; @@ -117,7 +118,7 @@ int setup_tests() { #else -int setup_tests() +int setup_tests(void) { return 1; }