Delete the filesystem used by wxWebViewArchiveHandler when we are done with it. Fixes a memory leak.

Closes #13500

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@69316 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Steve Lamerton 2011-10-05 21:21:51 +00:00
parent 3949871086
commit f2ae0da1b5
2 changed files with 6 additions and 1 deletions

View File

@ -26,7 +26,7 @@ class WXDLLIMPEXP_WEBVIEW wxWebViewArchiveHandler : public wxWebViewHandler
{
public:
wxWebViewArchiveHandler(const wxString& scheme);
virtual ~wxWebViewArchiveHandler() {}
virtual ~wxWebViewArchiveHandler();
virtual wxFSFile* GetFile(const wxString &uri);
private:
wxFileSystem* m_fileSystem;

View File

@ -50,6 +50,11 @@ wxWebViewArchiveHandler::wxWebViewArchiveHandler(const wxString& scheme) :
m_fileSystem = new wxFileSystem();
}
wxWebViewArchiveHandler::~wxWebViewArchiveHandler()
{
wxDELETE(m_fileSystem);
}
wxFSFile* wxWebViewArchiveHandler::GetFile(const wxString &uri)
{
//If there is a fragment at the end of the path then we need to strip it