<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN"
"http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head><meta http-equiv="content-type" content="text/html; charset=utf-8" />
<title>[211762] trunk/Source/WebCore</title>
</head>
<body>

<style type="text/css"><!--
#msg dl.meta { border: 1px #006 solid; background: #369; padding: 6px; color: #fff; }
#msg dl.meta dt { float: left; width: 6em; font-weight: bold; }
#msg dt:after { content:':';}
#msg dl, #msg dt, #msg ul, #msg li, #header, #footer, #logmsg { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt;  }
#msg dl a { font-weight: bold}
#msg dl a:link    { color:#fc3; }
#msg dl a:active  { color:#ff0; }
#msg dl a:visited { color:#cc6; }
h3 { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt; font-weight: bold; }
#msg pre { overflow: auto; background: #ffc; border: 1px #fa0 solid; padding: 6px; }
#logmsg { background: #ffc; border: 1px #fa0 solid; padding: 1em 1em 0 1em; }
#logmsg p, #logmsg pre, #logmsg blockquote { margin: 0 0 1em 0; }
#logmsg p, #logmsg li, #logmsg dt, #logmsg dd { line-height: 14pt; }
#logmsg h1, #logmsg h2, #logmsg h3, #logmsg h4, #logmsg h5, #logmsg h6 { margin: .5em 0; }
#logmsg h1:first-child, #logmsg h2:first-child, #logmsg h3:first-child, #logmsg h4:first-child, #logmsg h5:first-child, #logmsg h6:first-child { margin-top: 0; }
#logmsg ul, #logmsg ol { padding: 0; list-style-position: inside; margin: 0 0 0 1em; }
#logmsg ul { text-indent: -1em; padding-left: 1em; }#logmsg ol { text-indent: -1.5em; padding-left: 1.5em; }
#logmsg > ul, #logmsg > ol { margin: 0 0 1em 0; }
#logmsg pre { background: #eee; padding: 1em; }
#logmsg blockquote { border: 1px solid #fa0; border-left-width: 10px; padding: 1em 1em 0 1em; background: white;}
#logmsg dl { margin: 0; }
#logmsg dt { font-weight: bold; }
#logmsg dd { margin: 0; padding: 0 0 0.5em 0; }
#logmsg dd:before { content:'\00bb';}
#logmsg table { border-spacing: 0px; border-collapse: collapse; border-top: 4px solid #fa0; border-bottom: 1px solid #fa0; background: #fff; }
#logmsg table th { text-align: left; font-weight: normal; padding: 0.2em 0.5em; border-top: 1px dotted #fa0; }
#logmsg table td { text-align: right; border-top: 1px dotted #fa0; padding: 0.2em 0.5em; }
#logmsg table thead th { text-align: center; border-bottom: 1px solid #fa0; }
#logmsg table th.Corner { text-align: left; }
#logmsg hr { border: none 0; border-top: 2px dashed #fa0; height: 1px; }
#header, #footer { color: #fff; background: #636; border: 1px #300 solid; padding: 6px; }
#patch { width: 100%; }
#patch h4 {font-family: verdana,arial,helvetica,sans-serif;font-size:10pt;padding:8px;background:#369;color:#fff;margin:0;}
#patch .propset h4, #patch .binary h4 {margin:0;}
#patch pre {padding:0;line-height:1.2em;margin:0;}
#patch .diff {width:100%;background:#eee;padding: 0 0 10px 0;overflow:auto;}
#patch .propset .diff, #patch .binary .diff  {padding:10px 0;}
#patch span {display:block;padding:0 10px;}
#patch .modfile, #patch .addfile, #patch .delfile, #patch .propset, #patch .binary, #patch .copfile {border:1px solid #ccc;margin:10px 0;}
#patch ins {background:#dfd;text-decoration:none;display:block;padding:0 10px;}
#patch del {background:#fdd;text-decoration:none;display:block;padding:0 10px;}
#patch .lines, .info {color:#888;background:#fff;}
--></style>
<div id="msg">
<dl class="meta">
<dt>Revision</dt> <dd><a href="http://trac.webkit.org/projects/webkit/changeset/211762">211762</a></dd>
<dt>Author</dt> <dd>aestes@apple.com</dd>
<dt>Date</dt> <dd>2017-02-06 17:39:45 -0800 (Mon, 06 Feb 2017)</dd>
</dl>

<h3>Log Message</h3>
<pre>[Cocoa] Split FileSystemMac.mm into Mac and Cocoa parts
https://bugs.webkit.org/show_bug.cgi?id=167908

Reviewed by Sam Weinig.

Kept the Mac-only functions in FileSystemMac.mm and moved the rest into FileSystemCocoa.mm.

* PlatformMac.cmake:
* WebCore.xcodeproj/project.pbxproj:
* platform/cocoa/FileSystemCocoa.mm: Copied from Source/WebCore/platform/mac/FileSystemMac.mm.
* platform/mac/FileSystemMac.mm:
(-[WebFileManagerDelegate fileManager:shouldProceedAfterError:movingItemAtURL:toURL:]): Moved to FileSystemCocoa.mm.
(WebCore::homeDirectoryPath): Ditto.
(WebCore::openTemporaryFile): Ditto.
(WebCore::moveFile): Ditto.
(WebCore::getVolumeFreeSpace): Ditto.</pre>

<h3>Modified Paths</h3>
<ul>
<li><a href="#trunkSourceWebCoreChangeLog">trunk/Source/WebCore/ChangeLog</a></li>
<li><a href="#trunkSourceWebCorePlatformMaccmake">trunk/Source/WebCore/PlatformMac.cmake</a></li>
<li><a href="#trunkSourceWebCoreWebCorexcodeprojprojectpbxproj">trunk/Source/WebCore/WebCore.xcodeproj/project.pbxproj</a></li>
<li><a href="#trunkSourceWebCoreplatformmacFileSystemMacmm">trunk/Source/WebCore/platform/mac/FileSystemMac.mm</a></li>
</ul>

<h3>Added Paths</h3>
<ul>
<li><a href="#trunkSourceWebCoreplatformcocoaFileSystemCocoamm">trunk/Source/WebCore/platform/cocoa/FileSystemCocoa.mm</a></li>
</ul>

</div>
<div id="patch">
<h3>Diff</h3>
<a id="trunkSourceWebCoreChangeLog"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/ChangeLog (211761 => 211762)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/ChangeLog        2017-02-07 01:33:41 UTC (rev 211761)
+++ trunk/Source/WebCore/ChangeLog        2017-02-07 01:39:45 UTC (rev 211762)
</span><span class="lines">@@ -1,3 +1,22 @@
</span><ins>+2017-02-06  Andy Estes  &lt;aestes@apple.com&gt;
+
+        [Cocoa] Split FileSystemMac.mm into Mac and Cocoa parts
+        https://bugs.webkit.org/show_bug.cgi?id=167908
+
+        Reviewed by Sam Weinig.
+
+        Kept the Mac-only functions in FileSystemMac.mm and moved the rest into FileSystemCocoa.mm.
+
+        * PlatformMac.cmake:
+        * WebCore.xcodeproj/project.pbxproj:
+        * platform/cocoa/FileSystemCocoa.mm: Copied from Source/WebCore/platform/mac/FileSystemMac.mm.
+        * platform/mac/FileSystemMac.mm:
+        (-[WebFileManagerDelegate fileManager:shouldProceedAfterError:movingItemAtURL:toURL:]): Moved to FileSystemCocoa.mm.
+        (WebCore::homeDirectoryPath): Ditto.
+        (WebCore::openTemporaryFile): Ditto.
+        (WebCore::moveFile): Ditto.
+        (WebCore::getVolumeFreeSpace): Ditto.
+
</ins><span class="cx"> 2017-02-06  Eric Carlson  &lt;eric.carlson@apple.com&gt;
</span><span class="cx"> 
</span><span class="cx">         [MediaStream Mac] Remove some unused code
</span></span></pre></div>
<a id="trunkSourceWebCorePlatformMaccmake"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/PlatformMac.cmake (211761 => 211762)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/PlatformMac.cmake        2017-02-07 01:33:41 UTC (rev 211761)
+++ trunk/Source/WebCore/PlatformMac.cmake        2017-02-07 01:39:45 UTC (rev 211762)
</span><span class="lines">@@ -317,6 +317,7 @@
</span><span class="cx">     platform/cocoa/ContentFilterUnblockHandlerCocoa.mm
</span><span class="cx">     platform/cocoa/CoreVideoSoftLink.cpp
</span><span class="cx">     platform/cocoa/DisplaySleepDisablerCocoa.cpp
</span><ins>+    platform/cocoa/FileSystemCocoa.mm
</ins><span class="cx">     platform/cocoa/KeyEventCocoa.mm
</span><span class="cx">     platform/cocoa/LocalizedStringsCocoa.mm
</span><span class="cx">     platform/cocoa/MIMETypeRegistryCocoa.mm
</span></span></pre></div>
<a id="trunkSourceWebCoreWebCorexcodeprojprojectpbxproj"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/WebCore.xcodeproj/project.pbxproj (211761 => 211762)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/WebCore.xcodeproj/project.pbxproj        2017-02-07 01:33:41 UTC (rev 211761)
+++ trunk/Source/WebCore/WebCore.xcodeproj/project.pbxproj        2017-02-07 01:39:45 UTC (rev 211762)
</span><span class="lines">@@ -2049,7 +2049,7 @@
</span><span class="cx">                 5148453E1BB9D07E006A72ED /* IDBError.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 5148453C1BB9D076006A72ED /* IDBError.cpp */; };
</span><span class="cx">                 5148453F1BB9D07E006A72ED /* IDBError.h in Headers */ = {isa = PBXBuildFile; fileRef = 5148453D1BB9D076006A72ED /* IDBError.h */; settings = {ATTRIBUTES = (Private, ); }; };
</span><span class="cx">                 514B3F730C722047000530DF /* FileSystem.h in Headers */ = {isa = PBXBuildFile; fileRef = 514B3F720C722047000530DF /* FileSystem.h */; settings = {ATTRIBUTES = (Private, ); }; };
</span><del>-                514B3F760C722055000530DF /* FileSystemMac.mm in Sources */ = {isa = PBXBuildFile; fileRef = 514B3F750C722055000530DF /* FileSystemMac.mm */; };
</del><ins>+                514B3F760C722055000530DF /* FileSystemCocoa.mm in Sources */ = {isa = PBXBuildFile; fileRef = 514B3F750C722055000530DF /* FileSystemCocoa.mm */; };
</ins><span class="cx">                 514C76370CE9225E007EF3CD /* JSSQLError.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 514C76350CE9225E007EF3CD /* JSSQLError.cpp */; };
</span><span class="cx">                 514C76380CE9225E007EF3CD /* JSSQLTransaction.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 514C76360CE9225E007EF3CD /* JSSQLTransaction.cpp */; };
</span><span class="cx">                 514C764C0CE9234E007EF3CD /* AuthenticationMac.h in Headers */ = {isa = PBXBuildFile; fileRef = 514C76420CE9234E007EF3CD /* AuthenticationMac.h */; settings = {ATTRIBUTES = (Private, ); }; };
</span><span class="lines">@@ -3996,6 +3996,7 @@
</span><span class="cx">                 A1C150791E3F2B3E0032C98C /* PreviewConverter.mm in Sources */ = {isa = PBXBuildFile; fileRef = A1C150771E3F2B3E0032C98C /* PreviewConverter.mm */; };
</span><span class="cx">                 A1C1507A1E3F2B3E0032C98C /* PreviewConverter.h in Headers */ = {isa = PBXBuildFile; fileRef = A1C150781E3F2B3E0032C98C /* PreviewConverter.h */; };
</span><span class="cx">                 A1C7FAA2133A5D3500D6732D /* JSXPathResultCustom.cpp in Sources */ = {isa = PBXBuildFile; fileRef = A1C7FAA1133A5D3500D6732D /* JSXPathResultCustom.cpp */; };
</span><ins>+                A1CC11641E493D0100EFA69C /* FileSystemMac.mm in Sources */ = {isa = PBXBuildFile; fileRef = A1CC11621E493D0100EFA69C /* FileSystemMac.mm */; };
</ins><span class="cx">                 A1DE712D18612AC100734192 /* TouchEvents.cpp in Sources */ = {isa = PBXBuildFile; fileRef = A1DE712B18612AC100734192 /* TouchEvents.cpp */; };
</span><span class="cx">                 A1DE71321861322200734192 /* TouchConstructors.cpp in Sources */ = {isa = PBXBuildFile; fileRef = A1DE71301861322200734192 /* TouchConstructors.cpp */; };
</span><span class="cx">                 A1E1154413015C3D0054AC8C /* DistantLightSource.cpp in Sources */ = {isa = PBXBuildFile; fileRef = A1E1154313015C3D0054AC8C /* DistantLightSource.cpp */; };
</span><span class="lines">@@ -9349,7 +9350,7 @@
</span><span class="cx">                 5148453C1BB9D076006A72ED /* IDBError.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = IDBError.cpp; sourceTree = &quot;&lt;group&gt;&quot;; };
</span><span class="cx">                 5148453D1BB9D076006A72ED /* IDBError.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = IDBError.h; sourceTree = &quot;&lt;group&gt;&quot;; };
</span><span class="cx">                 514B3F720C722047000530DF /* FileSystem.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = FileSystem.h; sourceTree = &quot;&lt;group&gt;&quot;; };
</span><del>-                514B3F750C722055000530DF /* FileSystemMac.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = FileSystemMac.mm; sourceTree = &quot;&lt;group&gt;&quot;; };
</del><ins>+                514B3F750C722055000530DF /* FileSystemCocoa.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = FileSystemCocoa.mm; sourceTree = &quot;&lt;group&gt;&quot;; };
</ins><span class="cx">                 514C76350CE9225E007EF3CD /* JSSQLError.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = JSSQLError.cpp; sourceTree = &quot;&lt;group&gt;&quot;; };
</span><span class="cx">                 514C76360CE9225E007EF3CD /* JSSQLTransaction.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = JSSQLTransaction.cpp; sourceTree = &quot;&lt;group&gt;&quot;; };
</span><span class="cx">                 514C76420CE9234E007EF3CD /* AuthenticationMac.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = AuthenticationMac.h; sourceTree = &quot;&lt;group&gt;&quot;; };
</span><span class="lines">@@ -11769,6 +11770,7 @@
</span><span class="cx">                 A1C150771E3F2B3E0032C98C /* PreviewConverter.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = PreviewConverter.mm; sourceTree = &quot;&lt;group&gt;&quot;; };
</span><span class="cx">                 A1C150781E3F2B3E0032C98C /* PreviewConverter.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = PreviewConverter.h; sourceTree = &quot;&lt;group&gt;&quot;; };
</span><span class="cx">                 A1C7FAA1133A5D3500D6732D /* JSXPathResultCustom.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = JSXPathResultCustom.cpp; sourceTree = &quot;&lt;group&gt;&quot;; };
</span><ins>+                A1CC11621E493D0100EFA69C /* FileSystemMac.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = FileSystemMac.mm; sourceTree = &quot;&lt;group&gt;&quot;; };
</ins><span class="cx">                 A1DE712B18612AC100734192 /* TouchEvents.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = TouchEvents.cpp; sourceTree = &quot;&lt;group&gt;&quot;; };
</span><span class="cx">                 A1DE71301861322200734192 /* TouchConstructors.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = TouchConstructors.cpp; sourceTree = &quot;&lt;group&gt;&quot;; };
</span><span class="cx">                 A1E1154313015C3D0054AC8C /* DistantLightSource.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = DistantLightSource.cpp; sourceTree = &quot;&lt;group&gt;&quot;; };
</span><span class="lines">@@ -18000,7 +18002,7 @@
</span><span class="cx">                                 A7CFB3D40B7ED1180070C32D /* DragImageMac.mm */,
</span><span class="cx">                                 E1BA66F01742BD8600C20251 /* DynamicLinkerInterposing.h */,
</span><span class="cx">                                 1CA19E030DC255950065A994 /* EventLoopMac.mm */,
</span><del>-                                514B3F750C722055000530DF /* FileSystemMac.mm */,
</del><ins>+                                A1CC11621E493D0100EFA69C /* FileSystemMac.mm */,
</ins><span class="cx">                                 935C476E09AC4D7300A6AAB4 /* KeyEventMac.mm */,
</span><span class="cx">                                 521D46F511AEC98100514613 /* KillRingMac.mm */,
</span><span class="cx">                                 06E81ED60AB5D5E900C87837 /* LocalCurrentGraphicsContext.h */,
</span><span class="lines">@@ -20050,6 +20052,7 @@
</span><span class="cx">                                 7C7941E21C56C29300A4C58E /* DataDetectorsCoreSoftLink.mm */,
</span><span class="cx">                                 5D8C4DBD1428222C0026CE72 /* DisplaySleepDisablerCocoa.cpp */,
</span><span class="cx">                                 5D8C4DBE1428222C0026CE72 /* DisplaySleepDisablerCocoa.h */,
</span><ins>+                                514B3F750C722055000530DF /* FileSystemCocoa.mm */,
</ins><span class="cx">                                 A5C974CF11485FF10066F2AB /* KeyEventCocoa.h */,
</span><span class="cx">                                 A5C974D011485FF10066F2AB /* KeyEventCocoa.mm */,
</span><span class="cx">                                 1A4832B21A953BA6008B4DFE /* LocalizedStringsCocoa.mm */,
</span><span class="lines">@@ -29731,7 +29734,7 @@
</span><span class="cx">                                 C57FEDE11212EE9C0097BE65 /* FileSystem.cpp in Sources */,
</span><span class="cx">                                 5160306C0CC4362300C8AC25 /* FileSystemCF.cpp in Sources */,
</span><span class="cx">                                 26C17A3F1491D2D400D12BA2 /* FileSystemIOS.mm in Sources */,
</span><del>-                                514B3F760C722055000530DF /* FileSystemMac.mm in Sources */,
</del><ins>+                                514B3F760C722055000530DF /* FileSystemCocoa.mm in Sources */,
</ins><span class="cx">                                 5160300B0CC4251200C8AC25 /* FileSystemPOSIX.cpp in Sources */,
</span><span class="cx">                                 BC5EB69E0E81DAEB00B25965 /* FillLayer.cpp in Sources */,
</span><span class="cx">                                 08C925190FCC7C4A00480DEC /* FilterEffect.cpp in Sources */,
</span><span class="lines">@@ -30280,6 +30283,7 @@
</span><span class="cx">                                 BCD9C2620C17AA67005C90A2 /* JSDOMWindowCustom.cpp in Sources */,
</span><span class="cx">                                 460CBF351D4BCD0E0092E88E /* JSDOMWindowProperties.cpp in Sources */,
</span><span class="cx">                                 BCBFB53C0DCD29CF0019B3E5 /* JSDOMWindowShell.cpp in Sources */,
</span><ins>+                                A1CC11641E493D0100EFA69C /* FileSystemMac.mm in Sources */,
</ins><span class="cx">                                 4170A2EA1D8C0CCA00318452 /* JSDOMWrapper.cpp in Sources */,
</span><span class="cx">                                 93A8061D1E03B585008A1F26 /* JSDoubleRange.cpp in Sources */,
</span><span class="cx">                                 FD7868B9136B999200D403DF /* JSDynamicsCompressorNode.cpp in Sources */,
</span></span></pre></div>
<a id="trunkSourceWebCoreplatformcocoaFileSystemCocoammfromrev211761trunkSourceWebCoreplatformmacFileSystemMacmm"></a>
<div class="copfile"><h4>Copied: trunk/Source/WebCore/platform/cocoa/FileSystemCocoa.mm (from rev 211761, trunk/Source/WebCore/platform/mac/FileSystemMac.mm) (0 => 211762)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/platform/cocoa/FileSystemCocoa.mm                                (rev 0)
+++ trunk/Source/WebCore/platform/cocoa/FileSystemCocoa.mm        2017-02-07 01:39:45 UTC (rev 211762)
</span><span class="lines">@@ -0,0 +1,102 @@
</span><ins>+/*
+ * Copyright (C) 2007-2017 Apple Inc. All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ *
+ * 1.  Redistributions of source code must retain the above copyright
+ *     notice, this list of conditions and the following disclaimer. 
+ * 2.  Redistributions in binary form must reproduce the above copyright
+ *     notice, this list of conditions and the following disclaimer in the
+ *     documentation and/or other materials provided with the distribution. 
+ * 3.  Neither the name of Apple Inc. (&quot;Apple&quot;) nor the names of
+ *     its contributors may be used to endorse or promote products derived
+ *     from this software without specific prior written permission. 
+ *
+ * THIS SOFTWARE IS PROVIDED BY APPLE AND ITS CONTRIBUTORS &quot;AS IS&quot; AND ANY
+ * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+ * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+ * DISCLAIMED. IN NO EVENT SHALL APPLE OR ITS CONTRIBUTORS BE LIABLE FOR ANY
+ * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+ * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+ * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
+ * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+#import &quot;config.h&quot;
+#import &quot;FileSystem.h&quot;
+
+@interface WebFileManagerDelegate : NSObject &lt;NSFileManagerDelegate&gt;
+@end
+
+@implementation WebFileManagerDelegate
+
+- (BOOL)fileManager:(NSFileManager *)fileManager shouldProceedAfterError:(NSError *)error movingItemAtURL:(NSURL *)srcURL toURL:(NSURL *)dstURL
+{
+    UNUSED_PARAM(fileManager);
+    UNUSED_PARAM(srcURL);
+    UNUSED_PARAM(dstURL);    
+    return error.code == NSFileWriteFileExistsError;
+}
+
+@end
+
+namespace WebCore {
+
+String homeDirectoryPath()
+{
+    return NSHomeDirectory();
+}
+
+String openTemporaryFile(const String&amp; prefix, PlatformFileHandle&amp; platformFileHandle)
+{
+    platformFileHandle = invalidPlatformFileHandle;
+    
+    Vector&lt;char&gt; temporaryFilePath(PATH_MAX);
+    if (!confstr(_CS_DARWIN_USER_TEMP_DIR, temporaryFilePath.data(), temporaryFilePath.size()))
+        return String();
+
+    // Shrink the vector.   
+    temporaryFilePath.shrink(strlen(temporaryFilePath.data()));
+
+    // FIXME: Change to a runtime assertion that the path ends with a slash once &lt;rdar://problem/23579077&gt; is
+    // fixed in all iOS Simulator versions that we use.
+    if (temporaryFilePath.last() != '/')
+        temporaryFilePath.append('/');
+
+    // Append the file name.
+    CString prefixUtf8 = prefix.utf8();
+    temporaryFilePath.append(prefixUtf8.data(), prefixUtf8.length());
+    temporaryFilePath.append(&quot;XXXXXX&quot;, 6);
+    temporaryFilePath.append('\0');
+
+    platformFileHandle = mkstemp(temporaryFilePath.data());
+    if (platformFileHandle == invalidPlatformFileHandle)
+        return String();
+
+    return String::fromUTF8(temporaryFilePath.data());
+}
+
+bool moveFile(const String&amp; oldPath, const String&amp; newPath)
+{
+    // Overwrite existing files.
+    auto manager = adoptNS([[NSFileManager alloc] init]);
+    auto delegate = adoptNS([[WebFileManagerDelegate alloc] init]);
+    [manager setDelegate:delegate.get()];
+    
+    return [manager moveItemAtURL:[NSURL fileURLWithPath:oldPath] toURL:[NSURL fileURLWithPath:newPath] error:nil];
+}
+
+bool getVolumeFreeSpace(const String&amp; path, uint64_t&amp; freeSpace)
+{
+    NSDictionary *fileSystemAttributesDictionary = [[NSFileManager defaultManager] attributesOfFileSystemForPath:(NSString *)path error:NULL];
+    if (!fileSystemAttributesDictionary)
+        return false;
+    freeSpace = [[fileSystemAttributesDictionary objectForKey:NSFileSystemFreeSize] unsignedLongLongValue];
+    return true;
+}
+
+} // namespace WebCore
</ins></span></pre></div>
<a id="trunkSourceWebCoreplatformmacFileSystemMacmm"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/platform/mac/FileSystemMac.mm (211761 => 211762)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/platform/mac/FileSystemMac.mm        2017-02-07 01:33:41 UTC (rev 211761)
+++ trunk/Source/WebCore/platform/mac/FileSystemMac.mm        2017-02-07 01:39:45 UTC (rev 211762)
</span><span class="lines">@@ -1,113 +1,39 @@
</span><span class="cx"> /*
</span><del>- * Copyright (C) 2007, 2011 Apple Inc. All rights reserved.
</del><ins>+ * Copyright (C) 2007-2017 Apple Inc. All rights reserved.
</ins><span class="cx">  *
</span><span class="cx">  * Redistribution and use in source and binary forms, with or without
</span><span class="cx">  * modification, are permitted provided that the following conditions
</span><span class="cx">  * are met:
</span><ins>+ * 1. Redistributions of source code must retain the above copyright
+ *    notice, this list of conditions and the following disclaimer.
+ * 2. Redistributions in binary form must reproduce the above copyright
+ *    notice, this list of conditions and the following disclaimer in the
+ *    documentation and/or other materials provided with the distribution.
</ins><span class="cx">  *
</span><del>- * 1.  Redistributions of source code must retain the above copyright
- *     notice, this list of conditions and the following disclaimer. 
- * 2.  Redistributions in binary form must reproduce the above copyright
- *     notice, this list of conditions and the following disclaimer in the
- *     documentation and/or other materials provided with the distribution. 
- * 3.  Neither the name of Apple Inc. (&quot;Apple&quot;) nor the names of
- *     its contributors may be used to endorse or promote products derived
- *     from this software without specific prior written permission. 
- *
- * THIS SOFTWARE IS PROVIDED BY APPLE AND ITS CONTRIBUTORS &quot;AS IS&quot; AND ANY
- * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
- * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL APPLE OR ITS CONTRIBUTORS BE LIABLE FOR ANY
- * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
- * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
- * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
- * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
</del><ins>+ * THIS SOFTWARE IS PROVIDED BY APPLE INC. AND ITS CONTRIBUTORS ``AS IS''
+ * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
+ * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
+ * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR ITS CONTRIBUTORS
+ * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
+ * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
+ * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
+ * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
+ * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
+ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
+ * THE POSSIBILITY OF SUCH DAMAGE.
</ins><span class="cx">  */
</span><span class="cx"> 
</span><span class="cx"> #import &quot;config.h&quot;
</span><span class="cx"> #import &quot;FileSystem.h&quot;
</span><span class="cx"> 
</span><ins>+#if PLATFORM(MAC)
+
</ins><span class="cx"> #import &quot;WebCoreNSURLExtras.h&quot;
</span><span class="cx"> #import &quot;WebCoreSystemInterface.h&quot;
</span><del>-#import &lt;Foundation/FoundationErrors.h&gt;
-#import &lt;Foundation/NSFileManager.h&gt;
-#import &lt;wtf/RetainPtr.h&gt;
-#import &lt;wtf/text/CString.h&gt;
</del><span class="cx"> #import &lt;wtf/text/WTFString.h&gt;
</span><span class="cx"> 
</span><del>-@interface WebFileManagerDelegate : NSObject &lt;NSFileManagerDelegate&gt;
-@end
-
-@implementation WebFileManagerDelegate
-
-- (BOOL)fileManager:(NSFileManager *)fileManager shouldProceedAfterError:(NSError *)error movingItemAtURL:(NSURL *)srcURL toURL:(NSURL *)dstURL
-{
-    UNUSED_PARAM(fileManager);
-    UNUSED_PARAM(srcURL);
-    UNUSED_PARAM(dstURL);    
-    return error.code == NSFileWriteFileExistsError;
-}
-
-@end
-
</del><span class="cx"> namespace WebCore {
</span><span class="cx"> 
</span><del>-String homeDirectoryPath()
-{
-    return NSHomeDirectory();
-}
-
-String openTemporaryFile(const String&amp; prefix, PlatformFileHandle&amp; platformFileHandle)
-{
-    platformFileHandle = invalidPlatformFileHandle;
-    
-    Vector&lt;char&gt; temporaryFilePath(PATH_MAX);
-    if (!confstr(_CS_DARWIN_USER_TEMP_DIR, temporaryFilePath.data(), temporaryFilePath.size()))
-        return String();
-
-    // Shrink the vector.   
-    temporaryFilePath.shrink(strlen(temporaryFilePath.data()));
-
-    // FIXME: Change to a runtime assertion that the path ends with a slash once &lt;rdar://problem/23579077&gt; is
-    // fixed in all iOS Simulator versions that we use.
-    if (temporaryFilePath.last() != '/')
-        temporaryFilePath.append('/');
-
-    // Append the file name.
-    CString prefixUtf8 = prefix.utf8();
-    temporaryFilePath.append(prefixUtf8.data(), prefixUtf8.length());
-    temporaryFilePath.append(&quot;XXXXXX&quot;, 6);
-    temporaryFilePath.append('\0');
-
-    platformFileHandle = mkstemp(temporaryFilePath.data());
-    if (platformFileHandle == invalidPlatformFileHandle)
-        return String();
-
-    return String::fromUTF8(temporaryFilePath.data());
-}
-
-bool moveFile(const String&amp; oldPath, const String&amp; newPath)
-{
-    // Overwrite existing files.
-    auto manager = adoptNS([[NSFileManager alloc] init]);
-    auto delegate = adoptNS([[WebFileManagerDelegate alloc] init]);
-    [manager setDelegate:delegate.get()];
-    
-    return [manager moveItemAtURL:[NSURL fileURLWithPath:oldPath] toURL:[NSURL fileURLWithPath:newPath] error:nil];
-}
-
-bool getVolumeFreeSpace(const String&amp; path, uint64_t&amp; freeSpace)
-{
-    NSDictionary *fileSystemAttributesDictionary = [[NSFileManager defaultManager] attributesOfFileSystemForPath:(NSString *)path error:NULL];
-    if (!fileSystemAttributesDictionary)
-        return false;
-    freeSpace = [[fileSystemAttributesDictionary objectForKey:NSFileSystemFreeSize] unsignedLongLongValue];
-    return true;
-}
-
-#if !PLATFORM(IOS)
</del><span class="cx"> bool deleteEmptyDirectory(const String&amp; path)
</span><span class="cx"> {
</span><span class="cx">     auto fileManager = adoptNS([[NSFileManager alloc] init]);
</span><span class="lines">@@ -149,6 +75,6 @@
</span><span class="cx">     return true;
</span><span class="cx"> }
</span><span class="cx"> 
</span><del>-#endif
</del><ins>+} // namespace WebCore
</ins><span class="cx"> 
</span><del>-} // namespace WebCore
</del><ins>+#endif // PLATFORM(MAC)
</ins></span></pre>
</div>
</div>

</body>
</html>