| OLD | NEW |
| 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 #include "net/tools/flip_server/spdy_interface.h" | 5 #include "net/tools/flip_server/spdy_interface.h" |
| 6 | 6 |
| 7 #include <algorithm> | 7 #include <algorithm> |
| 8 #include <string> | 8 #include <string> |
| 9 | 9 |
| 10 #include "net/spdy/spdy_framer.h" | 10 #include "net/spdy/spdy_framer.h" |
| 11 #include "net/spdy/spdy_protocol.h" | 11 #include "net/spdy/spdy_protocol.h" |
| 12 #include "net/tools/dump_cache/url_utilities.h" | 12 #include "net/tools/dump_cache/url_utilities.h" |
| 13 #include "net/tools/flip_server/constants.h" | 13 #include "net/tools/flip_server/constants.h" |
| 14 #include "net/tools/flip_server/flip_config.h" | 14 #include "net/tools/flip_server/flip_config.h" |
| 15 #include "net/tools/flip_server/http_interface.h" | 15 #include "net/tools/flip_server/http_interface.h" |
| 16 #include "net/tools/flip_server/spdy_util.h" | 16 #include "net/tools/flip_server/spdy_util.h" |
| 17 | 17 |
| 18 namespace net { | 18 namespace net { |
| 19 | 19 |
| 20 // static | 20 // static |
| 21 std::string SpdySM::forward_ip_header_; | 21 std::string SpdySM::forward_ip_header_; |
| 22 | 22 |
| 23 class SpdyFrameDataFrame : public DataFrame { | 23 class SpdyFrameDataFrame : public DataFrame { |
| 24 public: | 24 public: |
| 25 explicit SpdyFrameDataFrame(SpdyFrame* spdy_frame) : frame(spdy_frame) { | 25 explicit SpdyFrameDataFrame(SpdyFrame* spdy_frame) : frame(spdy_frame) { |
| 26 data = spdy_frame->data(); | 26 data = spdy_frame->data(); |
| 27 size = spdy_frame->size(); | 27 size = spdy_frame->size(); |
| 28 } | 28 } |
| 29 | 29 |
| 30 virtual ~SpdyFrameDataFrame() { delete frame; } | 30 ~SpdyFrameDataFrame() override { delete frame; } |
| 31 | 31 |
| 32 const SpdyFrame* frame; | 32 const SpdyFrame* frame; |
| 33 }; | 33 }; |
| 34 | 34 |
| 35 SpdySM::SpdySM(SMConnection* connection, | 35 SpdySM::SpdySM(SMConnection* connection, |
| 36 SMInterface* sm_http_interface, | 36 SMInterface* sm_http_interface, |
| 37 EpollServer* epoll_server, | 37 EpollServer* epoll_server, |
| 38 MemoryCache* memory_cache, | 38 MemoryCache* memory_cache, |
| 39 FlipAcceptor* acceptor, | 39 FlipAcceptor* acceptor, |
| 40 SpdyMajorVersion spdy_version) | 40 SpdyMajorVersion spdy_version) |
| (...skipping 578 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 619 } | 619 } |
| 620 } | 620 } |
| 621 | 621 |
| 622 void SpdySM::CreateFramer(SpdyMajorVersion spdy_version) { | 622 void SpdySM::CreateFramer(SpdyMajorVersion spdy_version) { |
| 623 DCHECK(!buffered_spdy_framer_); | 623 DCHECK(!buffered_spdy_framer_); |
| 624 buffered_spdy_framer_.reset(new BufferedSpdyFramer(spdy_version, true)); | 624 buffered_spdy_framer_.reset(new BufferedSpdyFramer(spdy_version, true)); |
| 625 buffered_spdy_framer_->set_visitor(this); | 625 buffered_spdy_framer_->set_visitor(this); |
| 626 } | 626 } |
| 627 | 627 |
| 628 } // namespace net | 628 } // namespace net |
| OLD | NEW |