| 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/spdy/spdy_session.h" | 5 #include "net/spdy/spdy_session.h" |
| 6 | 6 |
| 7 #include <algorithm> | 7 #include <algorithm> |
| 8 #include <map> | 8 #include <map> |
| 9 | 9 |
| 10 #include "base/basictypes.h" | 10 #include "base/basictypes.h" |
| (...skipping 1965 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1976 | 1976 |
| 1977 if (clear_persisted) | 1977 if (clear_persisted) |
| 1978 http_server_properties_->ClearSpdySettings(host_port_pair()); | 1978 http_server_properties_->ClearSpdySettings(host_port_pair()); |
| 1979 | 1979 |
| 1980 if (net_log_.IsLogging()) { | 1980 if (net_log_.IsLogging()) { |
| 1981 net_log_.AddEvent( | 1981 net_log_.AddEvent( |
| 1982 NetLog::TYPE_SPDY_SESSION_RECV_SETTINGS, | 1982 NetLog::TYPE_SPDY_SESSION_RECV_SETTINGS, |
| 1983 base::Bind(&NetLogSpdySettingsCallback, host_port_pair(), | 1983 base::Bind(&NetLogSpdySettingsCallback, host_port_pair(), |
| 1984 clear_persisted)); | 1984 clear_persisted)); |
| 1985 } | 1985 } |
| 1986 |
| 1987 if (GetProtocolVersion() >= SPDY4) { |
| 1988 // Send an acknowledgment of the setting. |
| 1989 SpdySettingsIR settings_ir; |
| 1990 settings_ir.set_is_ack(true); |
| 1991 EnqueueSessionWrite( |
| 1992 HIGHEST, |
| 1993 SETTINGS, |
| 1994 scoped_ptr<SpdyFrame>( |
| 1995 buffered_spdy_framer_->SerializeFrame(settings_ir))); |
| 1996 } |
| 1986 } | 1997 } |
| 1987 | 1998 |
| 1988 void SpdySession::OnSetting(SpdySettingsIds id, | 1999 void SpdySession::OnSetting(SpdySettingsIds id, |
| 1989 uint8 flags, | 2000 uint8 flags, |
| 1990 uint32 value) { | 2001 uint32 value) { |
| 1991 CHECK(in_io_loop_); | 2002 CHECK(in_io_loop_); |
| 1992 | 2003 |
| 1993 if (availability_state_ == STATE_CLOSED) | 2004 if (availability_state_ == STATE_CLOSED) |
| 1994 return; | 2005 return; |
| 1995 | 2006 |
| (...skipping 1054 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3050 if (!queue->empty()) { | 3061 if (!queue->empty()) { |
| 3051 SpdyStreamId stream_id = queue->front(); | 3062 SpdyStreamId stream_id = queue->front(); |
| 3052 queue->pop_front(); | 3063 queue->pop_front(); |
| 3053 return stream_id; | 3064 return stream_id; |
| 3054 } | 3065 } |
| 3055 } | 3066 } |
| 3056 return 0; | 3067 return 0; |
| 3057 } | 3068 } |
| 3058 | 3069 |
| 3059 } // namespace net | 3070 } // namespace net |
| OLD | NEW |