Skip to content
  • mjs's avatar
    WebFoundation: · 69012bc6
    mjs authored
            Reviewed by Darin, Dave and Trey, and given the seal of approval by Don.
    
    	Added a new NSFileManager extension method which can be used to
    	remove a file but will refuse to remove a directory. Used it
    	wherever we remove files but not directories.
    
            * Misc.subproj/WebNSFileManagerExtras.h:
            * Misc.subproj/WebNSFileManagerExtras.m:
    	(-[NSFileManager _web_removeFileOnlyAtPath:]): New method that
    	removes a file using unlink(2), which means we can't possibly remove a directory.
    	Also unlink ._ file if we are on a filesystem that doesn't support a resource fork.
            * Database.subproj/WebFileDatabase.m:
            (-[WebFileDatabase _truncateToSizeLimit:]):  Use the new method.
            (-[WebFileDatabase performRemoveObjectForKey:]): Use the new method.
    
    WebKit:
    
            Reviewed by Darin, Dave and Trey, and given the seal of approval by Don.
    
    	Use new safer file removal call that does not handle directories.
    
            * Downloads.subproj/WebDownloadHandler.m:
    	(-[WebDownloadHandler cleanUpAfterFailure]): Use
    	_web_removeFileOnlyAtPath:
            * Plugins.subproj/WebBaseNetscapePluginStream.m:
            (-[WebBaseNetscapePluginStream dealloc]): Use _web_removeFileOnlyAtPath:
            (-[WebBaseNetscapePluginStream finishedLoadingWithData:]): Use _web_removeFileOnlyAtPath:
    
    
    git-svn-id: http://svn.webkit.org/repository/webkit/trunk@3324 268f45cc-cd09-0410-ab3c-d52691b4dbfc
    69012bc6