On Thu, 12 Mar 2026 11:31:54 GMT, David Beaumont <[email protected]> wrote:

>> src/java.base/share/classes/jdk/internal/jrtfs/SystemImage.java line 91:
>> 
>>> 89:     public static SystemImage fromDirectory(Path modulesDir, 
>>> PreviewMode mode) throws IOException {
>>> 90:         if (!Files.isDirectory(modulesDir)) {
>>> 91:             throw new 
>>> FileSystemNotFoundException(modulesDir.toString());
>> 
>> A `FileSystemNotFoundException` is not an `IOException`, should it instead 
>> just throw an `IOException`?
>
> This is just me splitting existing code apart (see line 77 in the original).
> I'd rather not change semantics/expectations in passing.

Right, pre-existing issue as FileSystemNotFoundException doesn't make sense 
here. NotDirectoryException would be better here but the outcome would be same, 
something is broken in the JDK build to get here.

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

PR Review Comment: https://git.openjdk.org/jdk/pull/29414#discussion_r3085284134

Reply via email to