Skip to content

Commit f744088

Browse files
committed
Avoid potential integer overflow in seconds->millis transformation
Closes gh-25613
1 parent 1a6a459 commit f744088

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

spring-context/src/main/java/org/springframework/context/support/AbstractResourceBasedMessageSource.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -178,7 +178,7 @@ protected boolean isFallbackToSystemLocale() {
178178
* a non-classpath location.
179179
*/
180180
public void setCacheSeconds(int cacheSeconds) {
181-
this.cacheMillis = (cacheSeconds * 1000);
181+
this.cacheMillis = cacheSeconds * 1000L;
182182
}
183183

184184
/**

0 commit comments

Comments
 (0)