aboutsummaryrefslogtreecommitdiff
path: root/src/java.base/share/classes/java/lang/System.java
diff options
context:
space:
mode:
authorRoger Riggs <rriggs@openjdk.org>2018-11-09 13:28:16 -0500
committerRoger Riggs <rriggs@openjdk.org>2018-11-09 13:28:16 -0500
commit29e742273eb1940925c9ecd1ced5d0320dccae01 (patch)
treeeced24515878cb222bd54dad577b21bf66b02059 /src/java.base/share/classes/java/lang/System.java
parent1b20a6781f3132ee1f23c795ed24dbf5e2d59b79 (diff)
downloadopenjdk-29e742273eb1940925c9ecd1ced5d0320dccae01.tar.gz
openjdk-29e742273eb1940925c9ecd1ced5d0320dccae01.zip
8185496: Improve performance of system properties initialization in initPhase1
8213424: VersionProps duplicate and skipped initialization Reviewed-by: mchung, redestad, dholmes
Diffstat (limited to 'src/java.base/share/classes/java/lang/System.java')
-rw-r--r--src/java.base/share/classes/java/lang/System.java3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/java.base/share/classes/java/lang/System.java b/src/java.base/share/classes/java/lang/System.java
index db8bcad66b4..755ba9d4fd2 100644
--- a/src/java.base/share/classes/java/lang/System.java
+++ b/src/java.base/share/classes/java/lang/System.java
@@ -802,6 +802,7 @@ public final class System {
if (props == null) {
props = new Properties();
initProperties(props);
+ VersionProps.init(props);
}
System.props = props;
}
@@ -1973,6 +1974,7 @@ public final class System {
// be put into it directly.
props = new Properties(84);
initProperties(props); // initialized by the VM
+ VersionProps.init(props);
// There are certain system configurations that may be controlled by
// VM options such as the maximum amount of direct memory and
@@ -1992,7 +1994,6 @@ public final class System {
lineSeparator = props.getProperty("line.separator");
StaticProperty.javaHome(); // Load StaticProperty to cache the property values
- VersionProps.init();
FileInputStream fdIn = new FileInputStream(FileDescriptor.in);
FileOutputStream fdOut = new FileOutputStream(FileDescriptor.out);