<?xml version="1.0" encoding="utf-8"?>
<feed xml:lang="en" xmlns="http://www.w3.org/2005/Atom"><title>Recent changes to patches</title><link href="https://sourceforge.net/p/simplexml/patches/" rel="alternate"/><link href="https://sourceforge.net/p/simplexml/patches/feed.atom" rel="self"/><id>https://sourceforge.net/p/simplexml/patches/</id><updated>2010-11-20T22:59:04Z</updated><subtitle>Recent changes to patches</subtitle><entry><title>Memory leak in parser-&gt;vbNextToken</title><link href="https://sourceforge.net/p/simplexml/patches/1/" rel="alternate"/><published>2010-11-20T22:59:04Z</published><updated>2010-11-20T22:59:04Z</updated><author><name>Dhiren Sham</name><uri>https://sourceforge.net/u/bloopsoft/</uri></author><id>https://sourceforge.net5d3096725cc69479e823cf06a8e6c191a93669cc</id><summary type="html">&lt;div class="markdown_content"&gt;&lt;p&gt;createSimpleXmlParser() allocates a buffer in parser-&amp;gt;vbNextToken by calling&lt;br /&gt;
parser-&amp;gt;vbNextToken= createSimpleXmlValueBuffer(512);&lt;br /&gt;
which in turn allocates the buffer by allocating the 512 bytes into vb-&amp;gt;sBuffer.&lt;br /&gt;
However, when destroySimpleXmlParser() is releasing resources, it merely calls free(parser-&amp;gt;vbNextToken), which leaks the actual buffer allocated in vb-&amp;gt;sBuffer.&lt;br /&gt;
A cleanup function, destroySimpleXmlValueBuffer() is already provided, but not used. This patch will replace the call to free() with a call to destroySimpleXmlValueBuffer() which will clean up both the buffer and the container object.&lt;/p&gt;&lt;/div&gt;</summary></entry></feed>