mirror of
https://github.com/openjdk/jdk.git
synced 2025-08-27 14:54:52 +02:00
8225037: java.net.JarURLConnection::getJarEntry() throws NullPointerException
Reviewed-by: coffeys, vtewari
This commit is contained in:
parent
04c0750041
commit
cc353da44d
2 changed files with 192 additions and 1 deletions
|
@ -254,7 +254,7 @@ public abstract class JarURLConnection extends URLConnection {
|
|||
* @see #getJarEntry
|
||||
*/
|
||||
public JarEntry getJarEntry() throws IOException {
|
||||
return getJarFile().getJarEntry(entryName);
|
||||
return entryName == null ? null : getJarFile().getJarEntry(entryName);
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue