Always print error messages from the last trapped exception to stderr. Optionally, print its stasktrace to stdout when in verbose mode.
Add relevant test. ------------- Commit messages: - Print all errors when jpackage is executed with verbose output. Prior the fix it suppressed printing last error messages to stderr. - Add test. Changes: https://git.openjdk.org/jdk/pull/24428/files Webrev: https://webrevs.openjdk.org/?repo=jdk&pr=24428&range=00 Issue: https://bugs.openjdk.org/browse/JDK-8353681 Stats: 70 lines in 3 files changed: 40 ins; 11 del; 19 mod Patch: https://git.openjdk.org/jdk/pull/24428.diff Fetch: git fetch https://git.openjdk.org/jdk.git pull/24428/head:pull/24428 PR: https://git.openjdk.org/jdk/pull/24428