mirror of
https://gitlab.gnome.org/GNOME/libxml2.git
synced 2025-03-09 04:58:16 +03:00
fix memory leak in xmlAllocOutputBuffer
This commit is contained in:
parent
1fc410d3d3
commit
4f67dbb0a1
1
xmlIO.c
Normal file → Executable file
1
xmlIO.c
Normal file → Executable file
@ -2383,6 +2383,7 @@ xmlAllocOutputBuffer(xmlCharEncodingHandlerPtr encoder) {
|
|||||||
if (encoder != NULL) {
|
if (encoder != NULL) {
|
||||||
ret->conv = xmlBufCreateSize(4000);
|
ret->conv = xmlBufCreateSize(4000);
|
||||||
if (ret->conv == NULL) {
|
if (ret->conv == NULL) {
|
||||||
|
xmlBufFree(ret->buffer);
|
||||||
xmlFree(ret);
|
xmlFree(ret);
|
||||||
return(NULL);
|
return(NULL);
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user