Details
-
Bug
-
Status: Open
-
Major
-
Resolution: Unresolved
-
1.2.0
-
None
-
None
Description
RunJar contains the lines
if (!file.exists() || !file.isFile()) { System.err.println("Not a valid JAR: " + file.getCanonicalPath()); System.exit(-1); }
This code fails with
Exception in thread "main" java.io.IOException: Invalid argument
at java.io.WinNTFileSystem.canonicalize0(Native Method)
at java.io.Win32FileSystem.canonicalize(Win32FileSystem.java:414)
at java.io.File.getCanonicalPath(File.java:589)
at org.apache.hadoop.util.RunJar.main(RunJar.java:85)
A possible fix is
if (!file.exists() || !file.isFile()) { System.err.println("Not a valid JAR: " + file); System.exit(-1); }
Attachments
Issue Links
- is broken by
-
HADOOP-8951 RunJar to fail with user-comprehensible error message if jar missing
- Closed