Bug 170795 - Clean up SharedBuffer public functions
Summary: Clean up SharedBuffer public functions
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: New Bugs (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Alex Christensen
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2017-04-12 15:51 PDT by Alex Christensen
Modified: 2017-04-13 14:48 PDT (History)
7 users (show)

See Also:


Attachments
Patch (4.23 KB, patch)
2017-04-12 15:53 PDT, Alex Christensen
no flags Details | Formatted Diff | Diff
Patch (4.90 KB, patch)
2017-04-12 22:33 PDT, Alex Christensen
buildbot: commit-queue-
Details | Formatted Diff | Diff
Archive of layout-test-results from ews121 for ios-simulator-wk2 (884.92 KB, application/zip)
2017-04-13 04:14 PDT, Build Bot
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Alex Christensen 2017-04-12 15:51:48 PDT
Clean up SharedBuffer public functions
Comment 1 Alex Christensen 2017-04-12 15:53:31 PDT
Created attachment 306947 [details]
Patch
Comment 2 Andreas Kling 2017-04-12 19:47:12 PDT
Comment on attachment 306947 [details]
Patch

r=me with gtk build fixed.
Comment 3 Alex Christensen 2017-04-12 22:33:30 PDT
Created attachment 306972 [details]
Patch
Comment 4 Build Bot 2017-04-13 04:14:33 PDT
Comment on attachment 306972 [details]
Patch

Attachment 306972 [details] did not pass ios-sim-ews (ios-simulator-wk2):
Output: http://webkit-queues.webkit.org/results/3528364

New failing tests:
webrtc/no-port-zero-in-upd-candidates.html
Comment 5 Build Bot 2017-04-13 04:14:35 PDT
Created attachment 306983 [details]
Archive of layout-test-results from ews121 for ios-simulator-wk2

The attached test failures were seen while running run-webkit-tests on the ios-sim-ews.
Bot: ews121  Port: ios-simulator-wk2  Platform: Mac OS X 10.11.6
Comment 6 Alex Christensen 2017-04-13 08:29:54 PDT
http://trac.webkit.org/r215319
Comment 7 Darin Adler 2017-04-13 11:29:31 PDT
Comment on attachment 306972 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=306972&action=review

> Source/WebCore/platform/SharedBuffer.cpp:234
> -void SharedBuffer::append(const Vector<char>& data)
> +void SharedBuffer::append(Vector<char>&& data)

This is a strange change. The function never takes ownership of this Vector, yet the signature implies it might. Why?
Comment 8 Alex Christensen 2017-04-13 11:30:49 PDT
I have plans to make it take ownership of a vector.  Right now all the callers of this function give the Vector to the SharedBuffer, and I want to keep it that way.
Comment 9 Darin Adler 2017-04-13 11:55:09 PDT
(In reply to Alex Christensen from comment #8)
> I have plans to make it take ownership of a vector.

One good way to express that is a brief comment inside the implementation of the function. Helps make sure nobody reverses what you have done without understanding if you are away from the project for a while.
Comment 10 Alex Christensen 2017-04-13 14:48:01 PDT
Adding comment in https://bugs.webkit.org/show_bug.cgi?id=170828