jetty-9 handle null push strategy

This commit is contained in:
Greg Wilkins 2012-11-29 16:32:44 +11:00
parent 9931ddec94
commit 21f717078c
3 changed files with 3 additions and 3 deletions

View File

@ -894,7 +894,7 @@ public class StandardSession implements ISession, Parser.Listener, Dumpable
{ {
if (flushing || queue.isEmpty()) if (flushing || queue.isEmpty())
return; return;
Set<IStream> stalledStreams = null; Set<IStream> stalledStreams = null;
for (int i = 0; i < queue.size(); ++i) for (int i = 0; i < queue.size(); ++i)
{ {

View File

@ -67,7 +67,7 @@ public class HttpTransportOverSPDY implements HttpTransport
this.connector = connector; this.connector = connector;
this.configuration = configuration; this.configuration = configuration;
this.endPoint = endPoint; this.endPoint = endPoint;
this.pushStrategy = pushStrategy; this.pushStrategy = pushStrategy==null?new PushStrategy.None():pushStrategy;
this.stream = stream; this.stream = stream;
this.requestHeaders = requestHeaders; this.requestHeaders = requestHeaders;
} }

View File

@ -118,7 +118,7 @@ public class TestServer
// Spdy Connector // Spdy Connector
SPDYServerConnectionFactory.checkNPNAvailable(); SPDYServerConnectionFactory.checkNPNAvailable();
PushStrategy push = new ReferrerPushStrategy(); PushStrategy push = null; /*new ReferrerPushStrategy();*/
HTTPSPDYServerConnectionFactory spdy2 = new HTTPSPDYServerConnectionFactory(2,config,push); HTTPSPDYServerConnectionFactory spdy2 = new HTTPSPDYServerConnectionFactory(2,config,push);
spdy2.setInputBufferSize(8192); spdy2.setInputBufferSize(8192);
spdy2.setInitialWindowSize(32768); spdy2.setInitialWindowSize(32768);