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

Side by Side Diff: net/http/http_stream_parser.h

Issue 25312002: net: don't preserve 1xx responses in parser buffer. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: .. Created 7 years, 2 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « net/http/http_proxy_client_socket_pool_unittest.cc ('k') | net/http/http_stream_parser.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef NET_HTTP_HTTP_STREAM_PARSER_H_ 5 #ifndef NET_HTTP_HTTP_STREAM_PARSER_H_
6 #define NET_HTTP_HTTP_STREAM_PARSER_H_ 6 #define NET_HTTP_HTTP_STREAM_PARSER_H_
7 7
8 #include <string> 8 #include <string>
9 9
10 #include "base/basictypes.h" 10 #include "base/basictypes.h"
(...skipping 160 matching lines...) Expand 10 before | Expand all | Expand 10 after
171 // The request to send. 171 // The request to send.
172 const HttpRequestInfo* request_; 172 const HttpRequestInfo* request_;
173 173
174 // The request header data. 174 // The request header data.
175 scoped_refptr<DrainableIOBuffer> request_headers_; 175 scoped_refptr<DrainableIOBuffer> request_headers_;
176 176
177 // Temporary buffer for reading. 177 // Temporary buffer for reading.
178 scoped_refptr<GrowableIOBuffer> read_buf_; 178 scoped_refptr<GrowableIOBuffer> read_buf_;
179 179
180 // Offset of the first unused byte in |read_buf_|. May be nonzero due to 180 // Offset of the first unused byte in |read_buf_|. May be nonzero due to
181 // a 1xx header, or body data in the same packet as header data. 181 // body data in the same packet as header data but is zero when reading
182 // headers.
182 int read_buf_unused_offset_; 183 int read_buf_unused_offset_;
183 184
184 // The amount beyond |read_buf_unused_offset_| where the status line starts; 185 // The amount beyond |read_buf_unused_offset_| where the status line starts;
185 // -1 if not found yet. 186 // -1 if not found yet.
186 int response_header_start_offset_; 187 int response_header_start_offset_;
187 188
188 // The parsed response headers. Owned by the caller. 189 // The parsed response headers. Owned by the caller.
189 HttpResponseInfo* response_; 190 HttpResponseInfo* response_;
190 191
191 // Indicates the content length. If this value is less than zero 192 // Indicates the content length. If this value is less than zero
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after
229 bool sent_last_chunk_; 230 bool sent_last_chunk_;
230 231
231 base::WeakPtrFactory<HttpStreamParser> weak_ptr_factory_; 232 base::WeakPtrFactory<HttpStreamParser> weak_ptr_factory_;
232 233
233 DISALLOW_COPY_AND_ASSIGN(HttpStreamParser); 234 DISALLOW_COPY_AND_ASSIGN(HttpStreamParser);
234 }; 235 };
235 236
236 } // namespace net 237 } // namespace net
237 238
238 #endif // NET_HTTP_HTTP_STREAM_PARSER_H_ 239 #endif // NET_HTTP_HTTP_STREAM_PARSER_H_
OLDNEW
« no previous file with comments | « net/http/http_proxy_client_socket_pool_unittest.cc ('k') | net/http/http_stream_parser.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698