update to latest servlet API behaviour

This commit is contained in:
Greg Wilkins 2017-07-18 13:11:53 +02:00
parent f4f6d834e7
commit 1956087277
2 changed files with 5 additions and 7 deletions

View File

@ -2446,8 +2446,7 @@ public class Request implements HttpServletRequest
{
throw new ServletException("HttpServletRequest.upgrade() not supported in Jetty");
}
public void setPathSpec(PathSpec pathSpec)
{
_pathSpec = pathSpec;
@ -2457,10 +2456,9 @@ public class Request implements HttpServletRequest
{
return _pathSpec;
}
// TODO replace with overriden version from API
public HttpServletMapping getMapping()
@Override
public HttpServletMapping getHttpServletMapping()
{
final PathSpec pathSpec = _pathSpec;
final MappingMatch match;
@ -2479,7 +2477,7 @@ public class Request implements HttpServletRequest
break;
case EXACT:
match = MappingMatch.EXACT;
mapping = _servletPath;
mapping = _servletPath.startsWith("/")?_servletPath.substring(1):_servletPath;
break;
case SUFFIX_GLOB:
match = MappingMatch.EXTENSION;

View File

@ -24,7 +24,7 @@ import static org.junit.Assert.assertNull;
import org.junit.Test;
@Deprecated
public class IPAddressMapTest
{
@Test