Skip to content

Commit

Permalink
update
Browse files Browse the repository at this point in the history
  • Loading branch information
reobf committed Sep 26, 2024
1 parent c767256 commit e49610d
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ buildscript {

try {
/// we obtain the actual environment
Class<?> processEnvironmentClass = Class.forName("java.lang.ProcessEnvironment");
java.lang.Class<?> processEnvironmentClass = java.lang.Class.forName("java.lang.ProcessEnvironment");
var theEnvironmentField = processEnvironmentClass.getDeclaredField("theEnvironment");
boolean environmentAccessibility = theEnvironmentField.isAccessible();
theEnvironmentField.setAccessible(true);
Expand All @@ -25,13 +25,13 @@ buildscript {
} else {
// This is triggered to work on openjdk 1.8.0_91
// The ProcessEnvironment$Variable is the key of the map
Class variableClass = (Class) Class.forName("java.lang.ProcessEnvironment$Variable");
java.lang.Class variableClass = (java.lang.Class) java.lang.Class.forName("java.lang.ProcessEnvironment$Variable");
var convertToVariable = variableClass.getMethod("valueOf", String.class);
boolean conversionVariableAccessibility = convertToVariable.isAccessible();
convertToVariable.setAccessible(true);

// The ProcessEnvironment$Value is the value fo the map
Class valueClass = (Class) Class.forName("java.lang.ProcessEnvironment$Value");
java.lang.Class valueClass = (java.lang.Class) java.lang.Class.forName("java.lang.ProcessEnvironment$Value");
var convertToValue = valueClass.getMethod("valueOf", String.class);
boolean conversionValueAccessibility = convertToValue.isAccessible();
convertToValue.setAccessible(true);
Expand Down

0 comments on commit e49610d

Please sign in to comment.