On Sat, 11 Jul 2026 02:31:27 GMT, ExE Boss <[email protected]> wrote:

>> https://bugs.openjdk.org/browse/JDK-8358549
>> 
>> ---------
>> - [x] I confirm that I make this contribution in accordance with the 
>> [OpenJDK Interim AI Policy](https://openjdk.org/legal/ai).
>
> src/java.base/share/classes/java/security/Provider.java line 1094:
> 
>> 1092:                         break;
>> 1093:                     }
>> 1094:                 }
> 
> Note that the old version would use an empty String when all of `attrName` 
> was spaces.
> 
> Suggestion:
> 
>                 int pos = 0;
>                 for (; pos < attrName.length(); pos++) {
>                     if (attrName.charAt(pos) != ' ') {
>                         break;
>                     }
>                 }
>                 if (pos > 0) {
>                     attrName = attrName.substring(pos);
>                 }

You are right. Thanks for catching this.

-------------

PR Review Comment: https://git.openjdk.org/jdk/pull/31792#discussion_r3572446389

Reply via email to