mirror of
				https://github.com/cuberite/polarssl.git
				synced 2025-11-03 20:22:59 -05:00 
			
		
		
		
	Serious bug fix in entropy.c
Bug: mutex access within entropy_contex after it has been zeroed leads to app crash.
This commit is contained in:
		
							parent
							
								
									cf201201e6
								
							
						
					
					
						commit
						638fa0bb0f
					
				@ -94,10 +94,10 @@ void entropy_free( entropy_context *ctx )
 | 
			
		||||
#if defined(POLARSSL_HAVEGE_C)
 | 
			
		||||
    havege_free( &ctx->havege_data );
 | 
			
		||||
#endif
 | 
			
		||||
    polarssl_zeroize( ctx, sizeof( entropy_context ) );
 | 
			
		||||
#if defined(POLARSSL_THREADING_C)
 | 
			
		||||
    polarssl_mutex_free( &ctx->mutex );
 | 
			
		||||
#endif
 | 
			
		||||
    polarssl_zeroize( ctx, sizeof( entropy_context ) );
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
int entropy_add_source( entropy_context *ctx,
 | 
			
		||||
 | 
			
		||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user