JDK-8170120 : jimage throws IOException when the given file is not a jimage file
  • Type: Bug
  • Component: tools
  • Sub-Component: jlink
  • Affected Version: 9
  • Priority: P4
  • Status: Resolved
  • Resolution: Fixed
  • OS: generic
  • CPU: generic
  • Submitted: 2016-11-21
  • Updated: 2018-02-23
  • Resolved: 2018-02-19
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 11
11 b02Fixed
Related Reports
Blocks :  
Duplicate :  
Relates :  
Relates :  
Relates :  
Relates :  
Relates :  
Description
The following tescases should be temporarily excluded to allow other tests to run.

JDK-8169713: JImageListTest.testListNoImageSpecified, JImageExtractTest.testExtractNoImageSpecified,
JImageVerifyTest.testVerifyImageNotSpecified

JDK-8169715: JImageListTest.testListEmptyFile, JImageListTest.testListNotAnImage, JImageExtractTest.testExtractNotAnImage,
JImageVerifyTest.testVerifyNotAnImage

JDK-8170113: JImageExtractTest.testExtractToReadOnlyDir, JImageExtractTest.testExtractToFile

JDK-8170114: JImageExtractTest.testExtractToNotEmptyDir

Comments
Discussed on jigsaw-dev here: http://mail.openjdk.java.net/pipermail/jigsaw-dev/2018-February/013610.html
17-02-2018

I update the description to reflect one issue identified from JDK-8194285. The test assumes it will print "Error: ...." like when the given file does not exist. jimage should probably handle consistently for the cases if the file does not exist or is not a valid jimage file.
18-01-2018