Title: [258565] trunk/Source/WebKit
Revision
258565
Author
[email protected]
Date
2020-03-17 11:33:58 -0700 (Tue, 17 Mar 2020)

Log Message

REGRESSION (r258334): WebPasteboardProxy::setPasteboardBufferForType should allow zero-size buffers
<https://webkit.org/b/209167>
<rdar://problem/60516302>

Reviewed by Geoffrey Garen.

* UIProcess/Cocoa/WebPasteboardProxyCocoa.mm:
(WebKit::WebPasteboardProxy::setPasteboardBufferForType):
- Remove check for zero-size buffer to match
  WebPageProxy::dataSelectionForPasteboard().

Modified Paths

Diff

Modified: trunk/Source/WebKit/ChangeLog (258564 => 258565)


--- trunk/Source/WebKit/ChangeLog	2020-03-17 18:31:22 UTC (rev 258564)
+++ trunk/Source/WebKit/ChangeLog	2020-03-17 18:33:58 UTC (rev 258565)
@@ -1,3 +1,16 @@
+2020-03-17  David Kilzer  <[email protected]>
+
+        REGRESSION (r258334): WebPasteboardProxy::setPasteboardBufferForType should allow zero-size buffers
+        <https://webkit.org/b/209167>
+        <rdar://problem/60516302>
+
+        Reviewed by Geoffrey Garen.
+
+        * UIProcess/Cocoa/WebPasteboardProxyCocoa.mm:
+        (WebKit::WebPasteboardProxy::setPasteboardBufferForType):
+        - Remove check for zero-size buffer to match
+          WebPageProxy::dataSelectionForPasteboard().
+
 2020-03-17  Brent Fulgham  <[email protected]>
 
         Terminate the WebContent process when receiving invalid IPC from a WebInspector session

Modified: trunk/Source/WebKit/UIProcess/Cocoa/WebPasteboardProxyCocoa.mm (258564 => 258565)


--- trunk/Source/WebKit/UIProcess/Cocoa/WebPasteboardProxyCocoa.mm	2020-03-17 18:31:22 UTC (rev 258564)
+++ trunk/Source/WebKit/UIProcess/Cocoa/WebPasteboardProxyCocoa.mm	2020-03-17 18:33:58 UTC (rev 258565)
@@ -184,7 +184,7 @@
         return completionHandler(PlatformPasteboard(pasteboardName).setBufferForType(nullptr, pasteboardType));
 
     // SharedMemory::Handle::size() is rounded up to the nearest page.
-    MESSAGE_CHECK(size && size <= handle.size(), completionHandler(0));
+    MESSAGE_CHECK(size <= handle.size(), completionHandler(0));
 
     RefPtr<SharedMemory> sharedMemoryBuffer = SharedMemory::map(handle, SharedMemory::Protection::ReadOnly);
     if (!sharedMemoryBuffer)
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to