mirror of
				https://gitlab.gnome.org/GNOME/libxml2.git
				synced 2025-10-24 13:33:01 +03:00 
			
		
		
		
	Fix an allocation error when copying entities
This commit is contained in:
		
							
								
								
									
										2
									
								
								parser.c
									
									
									
									
									
								
							
							
						
						
									
										2
									
								
								parser.c
									
									
									
									
									
								
							| @@ -2709,7 +2709,7 @@ xmlStringLenDecodeEntities(xmlParserCtxtPtr ctxt, const xmlChar *str, int len, | ||||
|  | ||||
| 		buffer[nbchars++] = '&'; | ||||
| 		if (nbchars > buffer_size - i - XML_PARSER_BUFFER_SIZE) { | ||||
| 		    growBuffer(buffer, XML_PARSER_BUFFER_SIZE); | ||||
| 		    growBuffer(buffer, i + XML_PARSER_BUFFER_SIZE); | ||||
| 		} | ||||
| 		for (;i > 0;i--) | ||||
| 		    buffer[nbchars++] = *cur++; | ||||
|   | ||||
		Reference in New Issue
	
	Block a user