mirror of https://github.com/openssl/openssl.git
				
				
				
			Ensure that the fake rand is initialized
Reviewed-by: Paul Dale <pauli@openssl.org> (Merged from https://github.com/openssl/openssl/pull/14299)
This commit is contained in:
		
							parent
							
								
									75de543635
								
							
						
					
					
						commit
						0c84139c98
					
				|  | @ -177,6 +177,14 @@ OSSL_PROVIDER *fake_rand_start(OSSL_LIB_CTX *libctx) | |||
|             || !TEST_true(RAND_set_DRBG_type(libctx, "fake", NULL, NULL, NULL)) | ||||
|             || !TEST_ptr(p = OSSL_PROVIDER_try_load(libctx, "fake-rand", 1))) | ||||
|         return NULL; | ||||
| 
 | ||||
|     /* Ensure that the fake rand is initialized. */ | ||||
|     if (!TEST_ptr(RAND_get0_private(libctx)) | ||||
|             || !TEST_ptr(RAND_get0_public(libctx))) { | ||||
|         OSSL_PROVIDER_unload(p); | ||||
|         return NULL; | ||||
|     } | ||||
| 
 | ||||
|     return p; | ||||
| } | ||||
| 
 | ||||
|  |  | |||
		Loading…
	
		Reference in New Issue