GH-9620: Use Locale.ROOT for neutral, case insensitive comparisons
Fixes: #9620 Issue link: https://github.com/spring-projects/spring-integration/issues/9620 **Auto-cherry-pick to `6.3.x` & `6.2.x`**
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2014-2023 the original author or authors.
|
||||
* Copyright 2014-2024 the original author or authors.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
@@ -19,6 +19,7 @@ package org.springframework.integration.websocket;
|
||||
import java.util.ArrayList;
|
||||
import java.util.Collections;
|
||||
import java.util.List;
|
||||
import java.util.Locale;
|
||||
import java.util.Map;
|
||||
import java.util.concurrent.ConcurrentHashMap;
|
||||
import java.util.concurrent.locks.Lock;
|
||||
@@ -124,7 +125,7 @@ public abstract class IntegrationWebSocketContainer implements DisposableBean {
|
||||
|
||||
public void addSupportedProtocols(String... protocols) {
|
||||
for (String protocol : protocols) {
|
||||
this.supportedProtocols.add(protocol.toLowerCase());
|
||||
this.supportedProtocols.add(protocol.toLowerCase(Locale.ROOT));
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user