Bug 209167 - REGRESSION (r258334): WebPasteboardProxy::setPasteboardBufferForType should allow zero-size buffers
Summary: REGRESSION (r258334): WebPasteboardProxy::setPasteboardBufferForType should a...
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: WebKit2 (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: David Kilzer (:ddkilzer)
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2020-03-16 20:46 PDT by David Kilzer (:ddkilzer)
Modified: 2020-03-17 11:34 PDT (History)
5 users (show)

See Also:


Attachments
Patch v1 (1.77 KB, patch)
2020-03-16 20:47 PDT, David Kilzer (:ddkilzer)
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description David Kilzer (:ddkilzer) 2020-03-16 20:46:04 PDT
WebPasteboardProxy::setPasteboardBufferForType should allow zero-size buffers.

<rdar://problem/60516302>
Comment 1 David Kilzer (:ddkilzer) 2020-03-16 20:47:33 PDT
Created attachment 393723 [details]
Patch v1
Comment 2 David Kilzer (:ddkilzer) 2020-03-16 20:50:22 PDT
As noted in the radar, I was unable to create a test for this.

Changing Tools/TestWebKitAPI/Tests/WebKit/execCopy.html to contain only a single non-breaking space does not make the `size` parameter go to zero when running this test:

$ ./Tools/Scripts/run-api-tests --release --no-build TestWebKitAPI.WebKit.PasteboardNotifications

Changing execCopy.html to contain no copyable content makes the test hang.
Comment 3 Geoffrey Garen 2020-03-17 10:07:27 PDT
Comment on attachment 393723 [details]
Patch v1

r=me
Comment 4 WebKit Commit Bot 2020-03-17 11:34:03 PDT
Comment on attachment 393723 [details]
Patch v1

Clearing flags on attachment: 393723

Committed r258565: <https://trac.webkit.org/changeset/258565>
Comment 5 WebKit Commit Bot 2020-03-17 11:34:05 PDT
All reviewed patches have been landed.  Closing bug.