Remove QuicSession::RegisterStaticStream() and merge it into
QuicSession::ActivateStream().
As static_stream_map_ has been removed, static streams are getting less and
less distinct from normal streams. And now after preventing
v99_stream_id_manager from knowing about stream staticness, static streams are
all the same as dynamic streams only to be different in is_static_ field.
So I think it'd be a nice cleanup to have only one method.
gfe-relnote: code refactoring. No behavior change.
PiperOrigin-RevId: 267652775
Change-Id: I27137a225c69c0a41c644d473d59e7a4c3c64359
diff --git a/quic/core/quic_session_test.cc b/quic/core/quic_session_test.cc
index eafb0bd..4e419da 100644
--- a/quic/core/quic_session_test.cc
+++ b/quic/core/quic_session_test.cc
@@ -1388,8 +1388,7 @@
QuicUtils::GetHeadersStreamId(connection_->transport_version());
std::unique_ptr<TestStream> fake_headers_stream = QuicMakeUnique<TestStream>(
headers_stream_id, &session_, /*is_static*/ true, BIDIRECTIONAL);
- QuicSessionPeer::RegisterStaticStream(&session_,
- std::move(fake_headers_stream));
+ QuicSessionPeer::ActivateStream(&session_, std::move(fake_headers_stream));
// Send two bytes of payload.
QuicStreamFrame data1(headers_stream_id, true, 0, QuicStringPiece("HT"));
EXPECT_CALL(*connection_,
@@ -1407,8 +1406,7 @@
QuicUtils::GetHeadersStreamId(connection_->transport_version());
std::unique_ptr<TestStream> fake_headers_stream = QuicMakeUnique<TestStream>(
headers_stream_id, &session_, /*is_static*/ true, BIDIRECTIONAL);
- QuicSessionPeer::RegisterStaticStream(&session_,
- std::move(fake_headers_stream));
+ QuicSessionPeer::ActivateStream(&session_, std::move(fake_headers_stream));
// Send two bytes of payload.
QuicRstStreamFrame rst1(kInvalidControlFrameId, headers_stream_id,
QUIC_ERROR_PROCESSING_STREAM, 0);
@@ -2616,8 +2614,7 @@
QuicStreamId stream_id = 0;
std::unique_ptr<TestStream> fake_static_stream = QuicMakeUnique<TestStream>(
stream_id, &session_, /*is_static*/ true, BIDIRECTIONAL);
- QuicSessionPeer::RegisterStaticStream(&session_,
- std::move(fake_static_stream));
+ QuicSessionPeer::ActivateStream(&session_, std::move(fake_static_stream));
// Check that a stream id in the static stream map is ignored.
// Note that the notion of a static stream is Google-specific.
QuicStopSendingFrame frame(1, stream_id, 123);