Memory leak calling SetElementHtml, IE fault?

G

Guest

I experience a HUGE memory leak (in fact, a handle leak) calling
SetElementHtml.
In fact, it's the function put_innerHTML and some other one that are
responsible for that.

CString sHtmlContent = _T("Here is a memory leak");
BSTR bstr = m_sHtmlContent.AllocSysString();
for(int i = 0; i < 100; i++)
SetElementHtml("MyDIV" , bstr);
SysFreeString(bstr);

Each time I call this function i lose 4 handles !! So in this sample, I lose
about 400 handles !!!

It is a known issue? Are there any solutions? Thanks
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top