msxml3: Fix a memory leak (Valgrind).
Signed-off-by: Yongjie Yao <yaoyongjie@uniontech.com> Signed-off-by: Myah Caron <qsniyg@protonmail.com> Signed-off-by: Nikolay Sivov <nsivov@codeweavers.com> Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
parent
db1403c5de
commit
9336ec8faf
|
@ -797,13 +797,17 @@ static HRESULT domdoc_load_from_stream(domdoc *doc, ISequentialStream *stream)
|
|||
|
||||
hr = GetHGlobalFromStream(hstream, &hglobal);
|
||||
if (FAILED(hr))
|
||||
{
|
||||
IStream_Release(hstream);
|
||||
return hr;
|
||||
}
|
||||
|
||||
len = GlobalSize(hglobal);
|
||||
ptr = GlobalLock(hglobal);
|
||||
if (len)
|
||||
xmldoc = doparse(doc, ptr, len, XML_CHAR_ENCODING_NONE);
|
||||
GlobalUnlock(hglobal);
|
||||
IStream_Release(hstream);
|
||||
|
||||
if (!xmldoc)
|
||||
{
|
||||
|
|
Loading…
Reference in New Issue