JDK-7083664 : TEST_BUG: test hard code of using c:/temp but this dir might not exist
  • Type: Bug
  • Component: security-libs
  • Sub-Component: java.security
  • Affected Version: 6,7,8
  • Priority: P4
  • Status: Closed
  • Resolution: Fixed
  • OS: windows
  • CPU: generic
  • Submitted: 2011-08-26
  • Updated: 2012-10-26
  • Resolved: 2012-09-04
The Version table provides details related to the release that this issue/RFE will be addressed.

Unresolved : Release in which this issue/RFE will be addressed.
Resolved: Release in which this issue/RFE has been resolved.
Fixed : Release in which this issue/RFE has been fixed. The release containing this fix may be available for download as an Early Access Release or a General Availability Release.

To download the current JDK release, click here.
JDK 6 JDK 7 JDK 8
6u34Fixed 7u40Fixed 8 b06Fixed
Description
sun/security/tools/jarsigner/diffend.sh

hard code of c:/temp

  Windows_* )
    NULL=NUL
    PS=";"
    FS="\\"
    CP="cp -f"
    TMP="c:/temp"
    ;;

c:/temp might not exist and test will just fail on such machine with no clear message for test requires c:/temp must exist

#section:shell
----------messages:(3/127)----------
command: shell diffend.sh []
reason: Assumed action based on file name: run shell diffend.sh 
elapsed time (seconds): 1.211
----------System.out:(1/49)----------
jarsigner: unable to open jar file: diffend.jar
----------System.err:(3/139)----------
rm: cannot unlink entry "diffend.jar": The system cannot find the file specified. 

zip error: Out of memory (allocating temp filename)
result: Failed. Execution failed: exit code 1


test result: Failed. Execution failed: exit code 1

Comments
EVALUATION remove all TMP settings in security tests: http://hg.openjdk.java.net/jdk8/tl/jdk/rev/f5120b47f93d
31-08-2011

SUGGESTED FIX Check whether c:/temp exist, if not, exit test with error message Or if [ -n "$TMPDIR" ]; then TMP="$TMPDIR" elif [ -d "$SystemDrive/Temp" ]; then TMP="$SystemDrive/Temp" elif [ -d "C:/Temp" ]; then TMP="C:/Temp" else TMP="/tmp" fi
26-08-2011

WORK AROUND Create c:/temp on test machine if it dose not exist
26-08-2011