Merge pull request #3527 from eclipse/jetty-9.4.x-3526-websocket_locales

Fixes #3526 - Request locale not retained in WebsocketUpgrade request.
This commit is contained in:
Simone Bordet 2019-04-05 22:59:13 +02:00 committed by GitHub
commit 9d45e1bfc7
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 6 additions and 0 deletions

View File

@ -123,6 +123,12 @@ public class UpgradeHttpServletRequest implements HttpServletRequest
attributes.put(name, httpRequest.getAttribute(name));
}
Enumeration<Locale> localeElements = httpRequest.getLocales();
while (localeElements.hasMoreElements())
{
locales.add(localeElements.nextElement());
}
localAddress = InetSocketAddress.createUnresolved(httpRequest.getLocalAddr(), httpRequest.getLocalPort());
localName = httpRequest.getLocalName();
remoteAddress = InetSocketAddress.createUnresolved(httpRequest.getRemoteAddr(), httpRequest.getRemotePort());