aboutsummaryrefslogtreecommitdiff
path: root/backends/platform
diff options
context:
space:
mode:
authorNicola Mettifogo2008-11-07 11:09:16 +0000
committerNicola Mettifogo2008-11-07 11:09:16 +0000
commit203db8686993aa1396dc771b49709f3914ccdec6 (patch)
treebee03e908098830e9044668bc5d71fcecb3c4077 /backends/platform
parent5bf81acb95cf92c9c45312a542c31aa3bc66a1cd (diff)
downloadscummvm-rg350-203db8686993aa1396dc771b49709f3914ccdec6.tar.gz
scummvm-rg350-203db8686993aa1396dc771b49709f3914ccdec6.tar.bz2
scummvm-rg350-203db8686993aa1396dc771b49709f3914ccdec6.zip
Fixed leaks in SearchMan. Default directories are now added with the 'autoFree' parameter set to true.
svn-id: r34926
Diffstat (limited to 'backends/platform')
-rw-r--r--backends/platform/sdl/sdl.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/backends/platform/sdl/sdl.cpp b/backends/platform/sdl/sdl.cpp
index 02c2efccdb..64766c2864 100644
--- a/backends/platform/sdl/sdl.cpp
+++ b/backends/platform/sdl/sdl.cpp
@@ -290,7 +290,7 @@ void OSystem_SDL::addSysArchivesToSearchSet(Common::SearchSet &s, int priority)
// FIXME: We use depth = 4 for now, to match the old code. May want to change that
Common::FSNode dataNode(DATA_PATH);
if (dataNode.exists() && dataNode.isDirectory()) {
- s.add(DATA_PATH, new Common::FSDirectory(dataNode, 4), priority);
+ s.add(DATA_PATH, new Common::FSDirectory(dataNode, 4), priority, true);
}
#endif
@@ -303,7 +303,7 @@ void OSystem_SDL::addSysArchivesToSearchSet(Common::SearchSet &s, int priority)
if (CFURLGetFileSystemRepresentation(fileUrl, true, buf, sizeof(buf))) {
// Success: Add it to the search path
Common::String bundlePath((const char *)buf);
- s.add("__OSX_BUNDLE__", new Common::FSDirectory(bundlePath), priority);
+ s.add("__OSX_BUNDLE__", new Common::FSDirectory(bundlePath), priority, true);
}
CFRelease(fileUrl);
}