Merge pull request #39856 from yokotaso

* pr/39856:
  Fix possible NullPointerException from getPermission()

Closes gh-39856
This commit is contained in:
Phillip Webb 2024-05-01 22:46:39 -07:00
commit bd16fc4d26
1 changed files with 1 additions and 1 deletions

View File

@ -172,7 +172,7 @@ final class JarUrlConnection extends java.net.JarURLConnection {
@Override
public Permission getPermission() throws IOException {
return this.jarFileConnection.getPermission();
return (this.jarFileConnection != null) ? this.jarFileConnection.getPermission() : null;
}
@Override