-
Notifications
You must be signed in to change notification settings - Fork 5.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
8293041: --disable-@files option doesn't work and cause an error #11183
Conversation
👋 Welcome back asotona! A progress list of the required criteria for merging this PR into |
Webrevs
|
Are you sure this is right place to do this? There are other "launcher options" that aren't passed through to CreateJavaVM and I'm surprised this one is. |
I've found this place as a single spot handling (or skipping) tons of options and as a source of the error message. Alternate suggestions are welcome, or link to relevant documentation, or an example of another filtered option. Thanks, |
I think I would start in ParseArguments (libjli/java.c) to see the options that are handled, translated, or passed through. I can't be 100% sure how this one should be handled without studying it more closely. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
As far as I can see @-file processing is a launcher feature, including the expansion of JDK_JAVA_OPTIONS, so it should never be getting passed through to the VM in the first place.
What I can't figure out is how the test tools/launcher/ArgsFileTest.java is working when the JVM won't start with that flag on the command-line ??
BTW for future reference for the test case we are no longer creating tests using the bug id as a directory, instead tests should be grouped into functional areas. Thanks. I was also surprised to see the i8N changes here as I thought that was normally handled seperately. |
…li/java.c ParseArguments DisableFilesOptionTest merged to ArgsFileTest::killSwitch help typo moved to a new bug
@dholmes-ora and @AlanBateman thanks for pointing me to the right place for the fix. tools/launcher/ArgsFileTest.java was working because it didn't contain any test with --disable-@files option verifying VM really starts |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good to see that this turned out to a simple change.
@asotona This change now passes all automated pre-integration checks. ℹ️ This project also has non-automated pre-integration requirements. Please see the file CONTRIBUTING.md for details. After integration, the commit message for the final commit will be:
You can use pull request commands such as /summary, /contributor and /issue to adjust it as needed. At the time when this comment was updated there had been 66 new commits pushed to the
As there are no conflicts, your changes will automatically be rebased on top of these commits when integrating. If you prefer to avoid this automatic rebasing, please check the documentation for the /integrate command for further details. ➡️ To integrate this PR with the above commit message to the |
/integrate |
Going to push as commit 13158cb.
Your commit was automatically rebased without conflicts. |
What about the killswitch test ?? |
KillSwitch test did not construct valid command line, it didn't expect VM to start correctly and so it didn't test the VM exit value. KillSwitch test just checked expanded options presence in the debug log (before passing to ParseArguments). |
Option --disable-@files is passed to VM option causing it to fail.
Proposed patch skips --disable-@files option in src/java.base/share/native/libjli/java.c ParseArguments processing, so it is not passed to the VM.
The patch also adds relevant test to ArgsFileTest.
Please review.
Thank you,
Adam
Progress
Issue
Reviewers
Reviewing
Using
git
Checkout this PR locally:
$ git fetch https://git.openjdk.org/jdk pull/11183/head:pull/11183
$ git checkout pull/11183
Update a local copy of the PR:
$ git checkout pull/11183
$ git pull https://git.openjdk.org/jdk pull/11183/head
Using Skara CLI tools
Checkout this PR locally:
$ git pr checkout 11183
View PR using the GUI difftool:
$ git pr show -t 11183
Using diff file
Download this PR as a diff file:
https://git.openjdk.org/jdk/pull/11183.diff