Fix recently introduced crash in wxFileSystem::OpenFile()

Fix the code after the changes of the recent b03850e367 (Reduce manual
memory management in wxFileSystemHandler code, 2026-07-20) which wrongly
destroyed the smart pointer too early.
This commit is contained in:
Vadim Zeitlin
2026-07-21 11:55:49 +02:00
parent 2650437c76
commit 895028b517
+1 -1
View File
@@ -295,7 +295,7 @@ wxFSFile* wxLocalFSHandler::OpenFile(wxFileSystem& WXUNUSED(fs), const wxString&
if ( !is->IsOk() )
return nullptr;
return new wxFSFile(is.get(),
return new wxFSFile(is.release(),
location,
wxEmptyString,
GetAnchor(location)