RFR: 8340380: Improve source launcher's shebang script detection [v3]

Athijegannathan Sundararajan sundar at openjdk.org
Fri Jan 10 08:40:35 UTC 2025


On Thu, 9 Jan 2025 09:20:51 GMT, Christian Stein <cstein at openjdk.org> wrote:

>> Please review this change that improves the launcher mode detection by reading the initial two characters from the started file for being a shebang script. It addresses the reported confusing error messages and also supports more shebang line variations. Including those line variations that omit the `--source` arguments like shown in the underlying issue description of JDK-8340380.
>> 
>> Tests of tier 1..3: _in progress_
>
> Christian Stein has updated the pull request incrementally with one additional commit since the last revision:
> 
>   Flip initial checks to restore original behaviour
>   
>   Avoid regression encoded in `test/jdk/tools/launcher/SourceMode.testClassNamedJava()` assertions

incremental changes look good to me

-------------

Marked as reviewed by sundar (Reviewer).

PR Review: https://git.openjdk.org/jdk/pull/21910#pullrequestreview-2541824395


More information about the core-libs-dev mailing list