mirror of https://github.com/openssl/openssl.git
				
				
				
			Fix a possible memory leak in load_builtin_compressions
Reviewed-by: Dmitry Belyavskiy <beldmit@gmail.com>
Reviewed-by: Paul Dale <pauli@openssl.org>
Reviewed-by: Hugo Landau <hlandau@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/22585)
(cherry picked from commit daf26c2d7a)
			
			
This commit is contained in:
		
							parent
							
								
									a9a1b3da87
								
							
						
					
					
						commit
						44c6554766
					
				|  | @ -465,7 +465,8 @@ DEFINE_RUN_ONCE_STATIC(do_load_builtin_compressions) | |||
|             comp->method = method; | ||||
|             comp->id = SSL_COMP_ZLIB_IDX; | ||||
|             comp->name = COMP_get_name(method); | ||||
|             sk_SSL_COMP_push(ssl_comp_methods, comp); | ||||
|             if (!sk_SSL_COMP_push(ssl_comp_methods, comp)) | ||||
|                 OPENSSL_free(comp); | ||||
|             sk_SSL_COMP_sort(ssl_comp_methods); | ||||
|         } | ||||
|     } | ||||
|  |  | |||
		Loading…
	
		Reference in New Issue