diff options
author | Simone Bordet | 2013-09-03 14:10:07 +0000 |
---|---|---|
committer | Simone Bordet | 2013-09-03 14:10:07 +0000 |
commit | 8422dd5b1ae85ca781f2e4671ccc468d8bcb8b6b (patch) | |
tree | 5970100ae7ec67831cc50d0f0771522f76cfe142 | |
parent | f10562f26919c523d8666c0c1026363a0dd6449c (diff) | |
download | org.eclipse.jetty.project-8422dd5b1ae85ca781f2e4671ccc468d8bcb8b6b.tar.gz org.eclipse.jetty.project-8422dd5b1ae85ca781f2e4671ccc468d8bcb8b6b.tar.xz org.eclipse.jetty.project-8422dd5b1ae85ca781f2e4671ccc468d8bcb8b6b.zip |
Relaxed accessibility modifiers of a few methods to support FCGI
parsing, and introduced method setResponseStatus(int) to set the
response status programmatically (since in FCGI the response line does
not exist and therefore it is not parsed).
-rw-r--r-- | jetty-http/src/main/java/org/eclipse/jetty/http/HttpParser.java | 16 |
1 files changed, 11 insertions, 5 deletions
diff --git a/jetty-http/src/main/java/org/eclipse/jetty/http/HttpParser.java b/jetty-http/src/main/java/org/eclipse/jetty/http/HttpParser.java index 9dc16b37f2..7cef1dcf53 100644 --- a/jetty-http/src/main/java/org/eclipse/jetty/http/HttpParser.java +++ b/jetty-http/src/main/java/org/eclipse/jetty/http/HttpParser.java @@ -100,7 +100,7 @@ public class HttpParser CHUNK, END, CLOSED - }; + } private final boolean DEBUG=LOG.isDebugEnabled(); // Cache debug to help branch prediction private final HttpHandler<ByteBuffer> _handler; @@ -204,6 +204,12 @@ public class HttpParser } /* ------------------------------------------------------------------------------- */ + protected void setResponseStatus(int status) + { + _responseStatus=status; + } + + /* ------------------------------------------------------------------------------- */ public State getState() { return _state; @@ -466,7 +472,7 @@ public class HttpParser if (_responseHandler!=null) { setState(State.STATUS); - _responseStatus=ch-'0'; + setResponseStatus(ch-'0'); } else { @@ -807,7 +813,7 @@ public class HttpParser /* * Parse the message headers and return true if the handler has signaled for a return */ - private boolean parseHeaders(ByteBuffer buffer) + protected boolean parseHeaders(ByteBuffer buffer) { boolean handle=false; @@ -1255,7 +1261,7 @@ public class HttpParser } } - private boolean parseContent(ByteBuffer buffer) + protected boolean parseContent(ByteBuffer buffer) { // Handle _content byte ch; @@ -1447,7 +1453,7 @@ public class HttpParser } /* ------------------------------------------------------------------------------- */ - private void setState(State state) + protected void setState(State state) { if (DEBUG) LOG.debug("{} --> {}",_state,state); |