Use rand instead of srand
diff --git a/tests/fuzz/fuzz_dtlsclient.c b/tests/fuzz/fuzz_dtlsclient.c
index 424af81..55cd43b 100644
--- a/tests/fuzz/fuzz_dtlsclient.c
+++ b/tests/fuzz/fuzz_dtlsclient.c
@@ -71,7 +71,7 @@
ret = mbedtls_ctr_drbg_random(p_rng, output, output_len);
for (i=0; i<output_len; i++) {
//replace result with pseudo random
- output[i] = (unsigned char) random();
+ output[i] = (unsigned char) rand();
}
return( ret );
}
@@ -86,7 +86,7 @@
//ret = mbedtls_entropy_func(data, output, len);
for (i=0; i<len; i++) {
//replace result with pseudo random
- output[i] = (unsigned char) random();
+ output[i] = (unsigned char) rand();
}
return( 0 );
}
@@ -121,7 +121,7 @@
mbedtls_ctr_drbg_init( &ctr_drbg );
mbedtls_entropy_init( &entropy );
- srandom(1);
+ srand(1);
if( mbedtls_ctr_drbg_seed( &ctr_drbg, dummy_entropy, &entropy,
(const unsigned char *) pers, strlen( pers ) ) != 0 )
goto exit;