buffer: add a method for getting only the first slice#14050
Merged
ggreenway merged 3 commits intoenvoyproxy:masterfrom Nov 19, 2020
Merged
buffer: add a method for getting only the first slice#14050ggreenway merged 3 commits intoenvoyproxy:masterfrom
ggreenway merged 3 commits intoenvoyproxy:masterfrom
Conversation
This is a minor cleanup in this commit, but more importantly it will be used in future changes to code in the performance critical path. Signed-off-by: Greg Greenway <ggreenway@apple.com>
jmarantz
previously approved these changes
Nov 19, 2020
Member
Author
|
/retest |
|
Retrying Azure Pipelines: |
Signed-off-by: Greg Greenway <ggreenway@apple.com>
I don't understand why this PR is changing coverage in source/server; it doesn't touch any files there, and should affect any calls into that code either. Signed-off-by: Greg Greenway <ggreenway@apple.com>
jmarantz
approved these changes
Nov 19, 2020
andreyprezotto
pushed a commit
to andreyprezotto/envoy
that referenced
this pull request
Nov 24, 2020
Signed-off-by: Greg Greenway <ggreenway@apple.com>
qqustc
pushed a commit
to qqustc/envoy
that referenced
this pull request
Nov 24, 2020
Signed-off-by: Greg Greenway <ggreenway@apple.com> Signed-off-by: Qin Qin <qqin@google.com>
htuch
reviewed
Nov 25, 2020
Member
htuch
left a comment
There was a problem hiding this comment.
Some post-submit drive-by comments.
| return {{const_cast<char*>(start()), size_}}; | ||
| } | ||
|
|
||
| Buffer::RawSlice frontSlice() const override { return {const_cast<char*>(start()), size_}; } |
Member
There was a problem hiding this comment.
It might be good to have the fuzzer actually call into this method, in addition to defining a fuzz variant.
| } | ||
|
|
||
| TEST_F(OwnedImplTest, FrontSlice) { | ||
| Buffer::OwnedImpl buffer; |
Member
There was a problem hiding this comment.
Are there any tests that cover the case when there are leading zero length slices?
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Signed-off-by: Greg Greenway ggreenway@apple.com
Commit Message:
Additional Description: This is a minor cleanup in this commit, but more importantly it will
be used in future changes to code in the performance critical path.
Risk Level: Low
Testing: All existing tests pass; added small new unittest
Docs Changes: none; internal change
Release Notes: none; internal change
Platform Specific Features: none
[Optional Runtime guard:]
[Optional Fixes #Issue]
[Optional Deprecated:]