mirror of
https://github.com/spring-projects/spring-framework
synced 2026-06-08 17:33:33 +00:00
Refine use of substring operations
Closes gh-25445
This commit is contained in:
+1
-1
@@ -107,7 +107,7 @@ public class TaskExecutorFactoryBean implements
|
||||
int separatorIndex = this.poolSize.indexOf('-');
|
||||
if (separatorIndex != -1) {
|
||||
corePoolSize = Integer.parseInt(this.poolSize.substring(0, separatorIndex));
|
||||
maxPoolSize = Integer.parseInt(this.poolSize.substring(separatorIndex + 1, this.poolSize.length()));
|
||||
maxPoolSize = Integer.parseInt(this.poolSize.substring(separatorIndex + 1));
|
||||
if (corePoolSize > maxPoolSize) {
|
||||
throw new IllegalArgumentException(
|
||||
"Lower bound of pool-size range must not exceed the upper bound");
|
||||
|
||||
Reference in New Issue
Block a user