| Index: net/quic/core/quic_session.cc
|
| diff --git a/net/quic/core/quic_session.cc b/net/quic/core/quic_session.cc
|
| index 032cc0052c1d38c7f6b6b16d547d092371f5dd65..7c1bf263417842c0957aeb5482dd6e935d23f0eb 100644
|
| --- a/net/quic/core/quic_session.cc
|
| +++ b/net/quic/core/quic_session.cc
|
| @@ -72,10 +72,6 @@ QuicSession::~QuicSession() {
|
| "still waiting for final byte offset: "
|
| << GetNumLocallyClosedOutgoingStreamsHighestOffset();
|
| QUIC_LOG_IF(WARNING, !zombie_streams_.empty()) << "Still have zombie streams";
|
| - for (const auto& kv : dynamic_stream_map_) {
|
| - QUIC_LOG_IF(WARNING, !kv.second->is_deletable())
|
| - << "Still have non-deletable stream";
|
| - }
|
| }
|
|
|
| void QuicSession::OnStreamFrame(const QuicStreamFrame& frame) {
|
| @@ -142,9 +138,8 @@ void QuicSession::OnConnectionClosed(QuicErrorCode error,
|
| // Cleanup zombie stream map on connection close.
|
| while (!zombie_streams_.empty()) {
|
| ZombieStreamMap::iterator it = zombie_streams_.begin();
|
| - // Do not call OnConnectionClose as this may trigger unexpected operations
|
| - // in subclass of QuicStream.
|
| - it->second->SetIsDeletable(true);
|
| + closed_streams_.push_back(std::move(it->second));
|
| + zombie_streams_.erase(it);
|
| }
|
|
|
| if (visitor_) {
|
| @@ -387,10 +382,10 @@ void QuicSession::CloseStreamInner(QuicStreamId stream_id, bool locally_reset) {
|
| stream->set_rst_sent(true);
|
| }
|
|
|
| - if (stream->is_deletable()) {
|
| - closed_streams_.push_back(std::move(it->second));
|
| - } else {
|
| + if (stream->IsWaitingForAcks()) {
|
| zombie_streams_[stream->id()] = std::move(it->second);
|
| + } else {
|
| + closed_streams_.push_back(std::move(it->second));
|
| }
|
|
|
| // If we haven't received a FIN or RST for this stream, we need to keep track
|
| @@ -966,7 +961,7 @@ QuicStream* QuicSession::CreateAndActivateStream(QuicStreamId id) {
|
| return stream_ptr;
|
| }
|
|
|
| -void QuicSession::MarkStreamDeletable(QuicStreamId id) {
|
| +void QuicSession::OnStreamDoneWaitingForAcks(QuicStreamId id) {
|
| auto it = zombie_streams_.find(id);
|
| if (it == zombie_streams_.end()) {
|
| return;
|
|
|