Changeset 228455 in webkit
- Timestamp:
- Feb 13, 2018 10:01:37 PM (6 years ago)
- Location:
- trunk/Source/WebKit
- Files:
-
- 16 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/WebKit/ChangeLog
r228451 r228455 1 2018-02-13 Yousuke Kimoto <yousuke.kimoto@sony.com> 2 3 [WinCairo] Fix build errors which come from including headers and not suitable implementation for windows 4 https://bugs.webkit.org/show_bug.cgi?id=182679 5 6 Reviewed by Michael Catanzaro. 7 8 * NetworkProcess/cache/NetworkCacheBlobStorage.cpp: 9 (WebKit::NetworkCache::BlobStorage::add): 10 * NetworkProcess/cache/NetworkCacheData.cpp: 11 (WebKit::NetworkCache::Data::mapToFile const): 12 (WebKit::NetworkCache::mapFile): 13 (WebKit::NetworkCache::adoptAndMapFile): 14 (WebKit::NetworkCache::readOrMakeSalt): 15 * NetworkProcess/cache/NetworkCacheFileSystem.cpp: 16 (WebKit::NetworkCache::directoryEntryType): 17 (WebKit::NetworkCache::traverseDirectory): 18 (WebKit::NetworkCache::fileTimes): 19 (WebKit::NetworkCache::updateFileModificationTimeIfNeeded): 20 * NetworkProcess/cache/NetworkCacheStorage.cpp: 21 (WebKit::NetworkCache::Storage::traverse): 22 * NetworkProcess/win/SystemProxyWin.h: 23 * Platform/IPC/Attachment.h: 24 * Platform/Module.h: 25 * Platform/SharedMemory.h: 26 * PluginProcess/WebProcessConnection.cpp: 27 * Shared/API/c/WKBase.h: 28 * Shared/ChildProcess.cpp: 29 * Shared/WebCoreArgumentCoders.h: 30 * UIProcess/ProcessAssertion.h: 31 * WebProcess/InjectedBundle/InjectedBundle.h: 32 * WebProcess/WebProcess.cpp: 33 1 34 2018-02-13 Commit Queue <commit-queue@webkit.org> 2 35 -
trunk/Source/WebKit/NetworkProcess/cache/NetworkCacheBlobStorage.cpp
r226423 r228455 31 31 #include <WebCore/FileSystem.h> 32 32 #include <fcntl.h> 33 #include <wtf/RunLoop.h> 34 #include <wtf/SHA1.h> 35 36 #if !OS(WINDOWS) 33 37 #include <sys/mman.h> 34 38 #include <sys/stat.h> 35 39 #include <unistd.h> 36 #include <wtf/RunLoop.h> 37 #include <wtf/SHA1.h> 40 #endif 38 41 39 42 namespace WebKit { … … 84 87 BlobStorage::Blob BlobStorage::add(const String& path, const Data& data) 85 88 { 89 #if !OS(WINDOWS) 86 90 ASSERT(!RunLoop::isMain()); 87 91 … … 115 119 116 120 return { mappedData, hash }; 121 #else 122 return { Data(), computeSHA1(data, m_salt) }; 123 #endif 117 124 } 118 125 -
trunk/Source/WebKit/NetworkProcess/cache/NetworkCacheData.cpp
r226423 r228455 29 29 #include <WebCore/FileSystem.h> 30 30 #include <fcntl.h> 31 #include <wtf/CryptographicallyRandomNumber.h> 32 33 #if !OS(WINDOWS) 31 34 #include <sys/mman.h> 32 35 #include <sys/stat.h> 33 36 #include <unistd.h> 34 # include <wtf/CryptographicallyRandomNumber.h>37 #endif 35 38 36 39 namespace WebKit { … … 39 42 Data Data::mapToFile(const char* path) const 40 43 { 44 #if !OS(WINDOWS) 41 45 int fd = open(path, O_CREAT | O_EXCL | O_RDWR , S_IRUSR | S_IWUSR); 42 46 if (fd < 0) … … 68 72 69 73 return Data::adoptMap(map, m_size, fd); 74 #else 75 return Data(); 76 #endif 70 77 } 71 78 72 79 Data mapFile(const char* path) 73 80 { 81 #if !OS(WINDOWS) 74 82 int fd = open(path, O_RDONLY, 0); 75 83 if (fd < 0) … … 87 95 88 96 return adoptAndMapFile(fd, 0, size); 97 #else 98 return Data(); 99 #endif 89 100 } 90 101 91 102 Data adoptAndMapFile(int fd, size_t offset, size_t size) 92 103 { 104 #if !OS(WINDOWS) 93 105 if (!size) { 94 106 close(fd); … … 103 115 104 116 return Data::adoptMap(map, size, fd); 117 #else 118 return Data(); 119 #endif 105 120 } 106 121 … … 139 154 std::optional<Salt> readOrMakeSalt(const String& path) 140 155 { 156 #if !OS(WINDOWS) 141 157 auto cpath = WebCore::FileSystem::fileSystemRepresentation(path); 142 158 auto fd = open(cpath.data(), O_RDONLY, 0); … … 155 171 } 156 172 return salt; 173 #else 174 return Salt(); 175 #endif 157 176 } 158 177 -
trunk/Source/WebKit/NetworkProcess/cache/NetworkCacheFileSystem.cpp
r226349 r228455 29 29 #include "Logging.h" 30 30 #include <WebCore/FileSystem.h> 31 #include <wtf/Assertions.h> 32 #include <wtf/Function.h> 33 #include <wtf/text/CString.h> 34 35 #if !OS(WINDOWS) 31 36 #include <dirent.h> 32 37 #include <sys/stat.h> 33 38 #include <sys/time.h> 34 #include <wtf/Assertions.h> 35 #include <wtf/Function.h> 36 #include <wtf/text/CString.h> 39 #endif 37 40 38 41 #if PLATFORM(IOS) && !PLATFORM(IOS_SIMULATOR) … … 51 54 static DirectoryEntryType directoryEntryType(uint8_t dtype) 52 55 { 56 #if !OS(WINDOWS) 53 57 switch (dtype) { 54 58 case DT_DIR: … … 60 64 return DirectoryEntryType::File; 61 65 } 66 #else 67 return DirectoryEntryType::File; 68 #endif 62 69 } 63 70 64 71 void traverseDirectory(const String& path, const Function<void (const String&, DirectoryEntryType)>& function) 65 72 { 73 #if !OS(WINDOWS) 66 74 DIR* dir = opendir(WebCore::FileSystem::fileSystemRepresentation(path).data()); 67 75 if (!dir) … … 80 88 } 81 89 closedir(dir); 90 #else 91 function(String(), DirectoryEntryType::File); 92 #endif 82 93 } 83 94 … … 117 128 return { WallTime::fromRawSeconds(g_ascii_strtoull(birthtimeString, nullptr, 10)), 118 129 WallTime::fromRawSeconds(g_file_info_get_attribute_uint64(fileInfo.get(), "time::modified")) }; 130 #elif OS(WINDOWS) 131 return FileTimes(); 119 132 #endif 120 133 } … … 128 141 return; 129 142 } 143 #if !OS(WINDOWS) 130 144 // This really updates both the access time and the modification time. 131 145 utimes(WebCore::FileSystem::fileSystemRepresentation(path).data(), nullptr); 146 #endif 132 147 } 133 148 -
trunk/Source/WebKit/NetworkProcess/cache/NetworkCacheStorage.cpp
r226349 r228455 909 909 910 910 const unsigned maximumParallelReadCount = 5; 911 traverseOperation.activeCondition.wait(lock, [&traverseOperation ] {911 traverseOperation.activeCondition.wait(lock, [&traverseOperation, maximumParallelReadCount] { 912 912 return traverseOperation.activeCount <= maximumParallelReadCount; 913 913 }); -
trunk/Source/WebKit/NetworkProcess/win/SystemProxyWin.h
r221625 r228455 24 24 */ 25 25 26 #pragma once 27 28 #include <windows.h> 29 26 30 class WindowsSystemProxy { 27 31 static const int ProxyServerNameLength = 512; -
trunk/Source/WebKit/Platform/IPC/Attachment.h
r224351 r228455 30 30 #include <mach/mach_init.h> 31 31 #include <mach/mach_traps.h> 32 #endif 33 34 #if OS(WINDOWS) 35 #include <windows.h> 32 36 #endif 33 37 -
trunk/Source/WebKit/Platform/Module.h
r223966 r228455 38 38 #endif 39 39 40 #if OS(WINDOWS) 41 #include <windows.h> 42 #endif 43 40 44 namespace WebKit { 41 45 … … 65 69 66 70 String m_path; 67 #if PLATFORM(WIN)71 #if OS(WINDOWS) 68 72 HMODULE m_module; 69 73 #endif -
trunk/Source/WebKit/Platform/SharedMemory.h
r223966 r228455 34 34 #include "Attachment.h" 35 35 #include <wtf/Optional.h> 36 #endif 37 38 #if OS(WINDOWS) 39 #include <windows.h> 36 40 #endif 37 41 -
trunk/Source/WebKit/PluginProcess/WebProcessConnection.cpp
r216448 r228455 39 39 #include "PluginProxyMessages.h" 40 40 #include "WebProcessConnectionMessages.h" 41 #include <wtf/SetForScope.h> 42 43 #if !OS(WINDOWS) 41 44 #include <unistd.h> 42 # include <wtf/SetForScope.h>45 #endif 43 46 44 47 using namespace WebCore; -
trunk/Source/WebKit/Shared/API/c/WKBase.h
r216696 r228455 33 33 #if defined(BUILDING_GTK__) 34 34 #include <WebKit/WKBaseGtk.h> 35 #e ndif36 37 # if defined(__APPLE__) && !defined(BUILDING_GTK__)35 #elif defined(BUILDING_WPE__) 36 #include <WebKit/WKBaseWPE.h> 37 #elif defined(__APPLE__) 38 38 #include <WebKit/WKBaseMac.h> 39 #endif 40 41 #if defined(BUILDING_WPE__) 42 #include <WebKit/WKBaseWPE.h> 39 #elif defined(_WIN32) 40 #include <WebKit/WKBaseWin.h> 43 41 #endif 44 42 -
trunk/Source/WebKit/Shared/ChildProcess.cpp
r226327 r228455 31 31 #include <WebCore/SchemeRegistry.h> 32 32 #include <pal/SessionID.h> 33 34 #if !OS(WINDOWS) 33 35 #include <unistd.h> 36 #endif 34 37 35 38 using namespace WebCore; -
trunk/Source/WebKit/Shared/WebCoreArgumentCoders.h
r226886 r228455 36 36 #include <WebCore/NetworkLoadMetrics.h> 37 37 #include <WebCore/NotificationDirection.h> 38 #include <WebCore/PaymentHeaders.h>39 38 #include <WebCore/RealtimeMediaSource.h> 40 39 #include <WebCore/ScrollSnapOffsetsInfo.h> … … 42 41 #include <WebCore/StoredCredentialsPolicy.h> 43 42 #include <WebCore/WorkerType.h> 43 44 #if ENABLE(APPLE_PAY) 45 #include <WebCore/PaymentHeaders.h> 46 #endif 44 47 45 48 namespace WTF { -
trunk/Source/WebKit/UIProcess/ProcessAssertion.h
r222422 r228455 27 27 #define ProcessAssertion_h 28 28 29 #include <unistd.h>30 29 #include <wtf/Function.h> 31 30 #include <wtf/ProcessID.h> 31 32 #if !OS(WINDOWS) 33 #include <unistd.h> 34 #endif 32 35 33 36 #if PLATFORM(IOS) && !PLATFORM(IOS_SIMULATOR) -
trunk/Source/WebKit/WebProcess/InjectedBundle/InjectedBundle.h
r226510 r228455 63 63 #elif USE(GLIB) 64 64 typedef ::GModule* PlatformBundle; 65 #elif OS(WINDOWS) 66 typedef void* PlatformBundle; 65 67 #endif 66 68 -
trunk/Source/WebKit/WebProcess/WebProcess.cpp
r228350 r228455 118 118 #include <WebCore/URLParser.h> 119 119 #include <WebCore/UserGestureIndicator.h> 120 #include <unistd.h>121 120 #include <wtf/CurrentTime.h> 122 121 #include <wtf/Language.h> 123 122 #include <wtf/RunLoop.h> 124 123 #include <wtf/text/StringHash.h> 124 125 #if !OS(WINDOWS) 126 #include <unistd.h> 127 #endif 125 128 126 129 #if PLATFORM(WAYLAND)
Note: See TracChangeset
for help on using the changeset viewer.