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

Unified Diff: net/tools/quic/quic_simple_server_session.cc

Issue 1874613002: relnote: add connection option "SPSH" to indicate whether client wants to do server push or not, wh… (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 8 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « net/tools/quic/quic_server_session_base_test.cc ('k') | net/tools/quic/quic_simple_server_session_test.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/tools/quic/quic_simple_server_session.cc
diff --git a/net/tools/quic/quic_simple_server_session.cc b/net/tools/quic/quic_simple_server_session.cc
index 8a31699e1636ac9feced4f125116e33e28501b66..946ac8a5b90eceba46179937f81bc108c12d678a 100644
--- a/net/tools/quic/quic_simple_server_session.cc
+++ b/net/tools/quic/quic_simple_server_session.cc
@@ -65,6 +65,10 @@ void QuicSimpleServerSession::PromisePushResources(
const std::list<QuicInMemoryCache::ServerPushInfo>& resources,
QuicStreamId original_stream_id,
const SpdyHeaderBlock& original_request_headers) {
+ if (!server_push_enabled()) {
+ return;
+ }
+
for (QuicInMemoryCache::ServerPushInfo resource : resources) {
SpdyHeaderBlock headers = SynthesizePushRequestHeaders(
request_url, resource, original_request_headers);
« no previous file with comments | « net/tools/quic/quic_server_session_base_test.cc ('k') | net/tools/quic/quic_simple_server_session_test.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698