-
Bug
-
Resolution: Fixed
-
P4
-
8-pool
-
b69
-
x86
-
windows_8
Issue | Fix Version | Assignee | Priority | Status | Resolution | Resolved In Build |
---|---|---|---|---|---|---|
JDK-8098771 | emb-9 | Michael Haupt | P4 | Resolved | Fixed | team |
JDK-8129204 | 8u65 | Michael Haupt | P4 | Resolved | Fixed | b02 |
JDK-8085896 | 8u60 | Michael Haupt | P4 | Resolved | Fixed | b20 |
JDK-8138538 | emb-8u65 | Unassigned | P4 | Resolved | Fixed | b02 |
JDK-8129729 | emb-8u60 | Michael Haupt | P4 | Resolved | Fixed | b20 |
FULL PRODUCT VERSION :
java version "1.8.0_45"
Java(TM) SE Runtime Environment (build 1.8.0_45-b14)
Java HotSpot(TM) 64-Bit Server VM (build 25.45-b02, mixed mode)
ADDITIONAL OS VERSION INFORMATION :
Microsoft Windows [Version 6.3.9600]
A DESCRIPTION OF THE PROBLEM :
In Nashorn shell scripting, the variable $ENV.PWD contains the current working directory, that is used when executing commands. However, initially, $ENV.PWD is undefined.
STEPS TO FOLLOW TO REPRODUCE THE PROBLEM :
Save the script below to a file "test.js" and run "jjs -scripting test.js" from the command-line.
print($ENV.PWD);
$ENV.PWD = "C:\\Users";
print($ENV.PWD);
EXPECTED VERSUS ACTUAL BEHAVIOR :
EXPECTED -
2 lines are printed: the first is the directory where you saved the script, the second is "C:\Users"
ACTUAL -
2 lines are printed: the first is "undefined", the second is "C:\Users"
REPRODUCIBILITY :
This bug can be reproduced always.
java version "1.8.0_45"
Java(TM) SE Runtime Environment (build 1.8.0_45-b14)
Java HotSpot(TM) 64-Bit Server VM (build 25.45-b02, mixed mode)
ADDITIONAL OS VERSION INFORMATION :
Microsoft Windows [Version 6.3.9600]
A DESCRIPTION OF THE PROBLEM :
In Nashorn shell scripting, the variable $ENV.PWD contains the current working directory, that is used when executing commands. However, initially, $ENV.PWD is undefined.
STEPS TO FOLLOW TO REPRODUCE THE PROBLEM :
Save the script below to a file "test.js" and run "jjs -scripting test.js" from the command-line.
print($ENV.PWD);
$ENV.PWD = "C:\\Users";
print($ENV.PWD);
EXPECTED VERSUS ACTUAL BEHAVIOR :
EXPECTED -
2 lines are printed: the first is the directory where you saved the script, the second is "C:\Users"
ACTUAL -
2 lines are printed: the first is "undefined", the second is "C:\Users"
REPRODUCIBILITY :
This bug can be reproduced always.
- backported by
-
JDK-8085896 Nashorn $ENV.PWD is originally undefined
-
- Resolved
-
-
JDK-8098771 Nashorn $ENV.PWD is originally undefined
-
- Resolved
-
-
JDK-8129204 Nashorn $ENV.PWD is originally undefined
-
- Resolved
-
-
JDK-8129729 Nashorn $ENV.PWD is originally undefined
-
- Resolved
-
-
JDK-8138538 Nashorn $ENV.PWD is originally undefined
-
- Resolved
-