Changeset 69118 in webkit
- Timestamp:
- Oct 5, 2010 10:01:07 AM (13 years ago)
- Location:
- trunk/WebCore
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/WebCore/ChangeLog
r69117 r69118 1 2010-10-05 Kwang Yul Seo <skyul@company100.net> 2 3 Reviewed by Kent Tamura. 4 5 [BREWMP] Use PlatformRefPtr instead of OwnPtr in FileSystem 6 https://bugs.webkit.org/show_bug.cgi?id=47025 7 8 PlatformRefPtr is a better choice here because all Brew MP instances are 9 reference counted. 10 11 * platform/brew/FileSystemBrew.cpp: 12 (WebCore::getFileSize): 13 (WebCore::fileExists): 14 (WebCore::deleteFile): 15 (WebCore::deleteEmptyDirectory): 16 (WebCore::canonicalPath): 17 (WebCore::makeAllDirectories): 18 (WebCore::openTemporaryFile): 19 1 20 2010-10-05 Martin Robinson <mrobinson@igalia.com> 2 21 -
trunk/WebCore/platform/brew/FileSystemBrew.cpp
r68342 r69118 38 38 #include <AEEStdLib.h> 39 39 40 #include <wtf/OwnPtr.h>41 #include <wtf/PassOwnPtr.h>42 40 #include <wtf/RandomNumber.h> 41 #include <wtf/brew/RefPtrBrew.h> 43 42 #include <wtf/brew/ShellBrew.h> 44 43 #include <wtf/text/CString.h> … … 48 47 bool getFileSize(const String& path, long long& result) 49 48 { 50 OwnPtr<IFileMgr> fileMgr = createInstance<IFileMgr>(AEECLSID_FILEMGR);49 PlatformRefPtr<IFileMgr> fileMgr = createRefPtrInstance<IFileMgr>(AEECLSID_FILEMGR); 51 50 FileInfo info; 52 51 … … 68 67 bool fileExists(const String& path) 69 68 { 70 OwnPtr<IFileMgr> fileMgr = createInstance<IFileMgr>(AEECLSID_FILEMGR);69 PlatformRefPtr<IFileMgr> fileMgr = createRefPtrInstance<IFileMgr>(AEECLSID_FILEMGR); 71 70 72 71 return (IFILEMGR_Test(fileMgr.get(), path.utf8().data()) == SUCCESS); … … 75 74 bool deleteFile(const String& path) 76 75 { 77 OwnPtr<IFileMgr> fileMgr = createInstance<IFileMgr>(AEECLSID_FILEMGR);76 PlatformRefPtr<IFileMgr> fileMgr = createRefPtrInstance<IFileMgr>(AEECLSID_FILEMGR); 78 77 79 78 return (IFILEMGR_Remove(fileMgr.get(), path.utf8().data()) == SUCCESS); … … 82 81 bool deleteEmptyDirectory(const String& path) 83 82 { 84 OwnPtr<IFileMgr> fileMgr = createInstance<IFileMgr>(AEECLSID_FILEMGR);83 PlatformRefPtr<IFileMgr> fileMgr = createRefPtrInstance<IFileMgr>(AEECLSID_FILEMGR); 85 84 86 85 return (IFILEMGR_RmDir(fileMgr.get(), path.utf8().data()) == SUCCESS); … … 111 110 static String canonicalPath(const String& path) 112 111 { 113 OwnPtr<IFileMgr> fileMgr = createInstance<IFileMgr>(AEECLSID_FILEMGR);112 PlatformRefPtr<IFileMgr> fileMgr = createRefPtrInstance<IFileMgr>(AEECLSID_FILEMGR); 114 113 115 114 // Get the buffer size required to resolve the path. … … 164 163 bool makeAllDirectories(const String& path) 165 164 { 166 OwnPtr<IFileMgr> fileMgr = createInstance<IFileMgr>(AEECLSID_FILEMGR);165 PlatformRefPtr<IFileMgr> fileMgr = createRefPtrInstance<IFileMgr>(AEECLSID_FILEMGR); 167 166 168 167 return makeAllDirectories(fileMgr.get(), canonicalPath(path)); … … 194 193 String tempPath("fs:/~/tmp"); 195 194 196 OwnPtr<IFileMgr> fileMgr = createInstance<IFileMgr>(AEECLSID_FILEMGR);195 PlatformRefPtr<IFileMgr> fileMgr = createRefPtrInstance<IFileMgr>(AEECLSID_FILEMGR); 197 196 198 197 // Create the temporary directory if it does not exist.
Note: See TracChangeset
for help on using the changeset viewer.