Signed-off-by: Joakim Erdfelt <joakim.erdfelt@gmail.com>
This commit is contained in:
parent
681f46bd2a
commit
34d27e8548
|
@ -38,7 +38,6 @@ import org.eclipse.jetty.http.BadMessageException;
|
|||
import org.eclipse.jetty.http.HttpFields;
|
||||
import org.eclipse.jetty.http.HttpGenerator;
|
||||
import org.eclipse.jetty.http.HttpHeader;
|
||||
import org.eclipse.jetty.http.HttpScheme;
|
||||
import org.eclipse.jetty.http.HttpStatus;
|
||||
import org.eclipse.jetty.http.HttpVersion;
|
||||
import org.eclipse.jetty.http.MetaData;
|
||||
|
@ -694,8 +693,6 @@ public class HttpChannel implements Runnable, HttpOutput.Interceptor
|
|||
|
||||
_request.setMetaData(request);
|
||||
|
||||
_request.setSecure(HttpScheme.HTTPS.is(request.getURI().getScheme()));
|
||||
|
||||
_combinedListener.onRequestBegin(_request);
|
||||
|
||||
if (LOG.isDebugEnabled())
|
||||
|
|
|
@ -1688,21 +1688,18 @@ public class Request implements HttpServletRequest
|
|||
final HttpURI uri = request.getURI();
|
||||
|
||||
if (uri.isAbsolute() && uri.hasAuthority() && uri.getPath() != null)
|
||||
{
|
||||
_uri = uri;
|
||||
}
|
||||
else
|
||||
{
|
||||
HttpURI.Mutable builder = HttpURI.build(uri);
|
||||
|
||||
if (uri.isAbsolute())
|
||||
{
|
||||
if (uri.getPath() == null)
|
||||
builder.path("/");
|
||||
setSecure(HttpScheme.HTTPS.is(uri.getScheme()));
|
||||
}
|
||||
else
|
||||
{
|
||||
if (!uri.isAbsolute())
|
||||
builder.scheme(HttpScheme.HTTP.asString());
|
||||
}
|
||||
|
||||
if (uri.getPath() == null)
|
||||
builder.path("/");
|
||||
|
||||
if (!uri.hasAuthority())
|
||||
{
|
||||
|
@ -1720,6 +1717,8 @@ public class Request implements HttpServletRequest
|
|||
_uri = builder.asImmutable();
|
||||
}
|
||||
|
||||
setSecure(HttpScheme.HTTPS.is(_uri.getScheme()));
|
||||
|
||||
String encoded = _uri.getPath();
|
||||
String path;
|
||||
if (encoded == null)
|
||||
|
|
Loading…
Reference in New Issue