Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(211)

Unified Diff: net/spdy/spdy_frame_builder.h

Issue 1852423004: Implement SpdySerializedFrame move semantics. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « net/spdy/spdy_buffer_unittest.cc ('k') | net/spdy/spdy_frame_builder_test.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/spdy/spdy_frame_builder.h
diff --git a/net/spdy/spdy_frame_builder.h b/net/spdy/spdy_frame_builder.h
index 29cb5546800fad5f461b6e7450208b022b6032bb..d1f9535f2f68a7176e2d2d44ba48b25178ca9d5b 100644
--- a/net/spdy/spdy_frame_builder.h
+++ b/net/spdy/spdy_frame_builder.h
@@ -74,13 +74,13 @@ class NET_EXPORT_PRIVATE SpdyFrameBuilder {
SpdyStreamId stream_id);
// Takes the buffer from the SpdyFrameBuilder.
- SpdyFrame* take() {
+ SpdySerializedFrame take() {
if (version_ == HTTP2) {
DLOG_IF(DFATAL, SpdyConstants::GetFrameMaximumSize(version_) < length_)
<< "Frame length " << length_
<< " is longer than the maximum allowed length.";
}
- SpdyFrame* rv = new SpdyFrame(buffer_.release(), length(), true);
+ SpdySerializedFrame rv(buffer_.release(), length(), true);
capacity_ = 0;
length_ = 0;
offset_ = 0;
« no previous file with comments | « net/spdy/spdy_buffer_unittest.cc ('k') | net/spdy/spdy_frame_builder_test.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698