fix memory leak when handling background attribute (patch 1687900)

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@45121 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Vadim Zeitlin
2007-03-29 18:12:59 +00:00
parent 6f45066bd8
commit a237d7ed48

View File

@@ -346,12 +346,12 @@ TAG_HANDLER_BEGIN(BODY, "BODY")
wxInputStream *is = fileBgImage->GetStream(); wxInputStream *is = fileBgImage->GetStream();
if ( is ) if ( is )
{ {
#if !defined(__WXMSW__) || wxUSE_WXDIB
wxImage image(*is); wxImage image(*is);
if ( image.Ok() ) if ( image.Ok() )
winIface->SetHTMLBackgroundImage(image); winIface->SetHTMLBackgroundImage(image);
#endif
} }
delete fileBgImage;
} }
} }