Mercurial > hg > release > icedtea6-1.8
changeset 2082:73442a614b23
Fix rhbz#560193
Process nested jars in applet code only if size > 0 bytes.
author | Deepak Bhole <dbhole@redhat.com> |
---|---|
date | Fri, 27 Aug 2010 14:50:02 -0400 |
parents | 01d87c70057a |
children | 9aa28151c299 |
files | ChangeLog NEWS netx/net/sourceforge/jnlp/runtime/JNLPClassLoader.java |
diffstat | 3 files changed, 16 insertions(+), 0 deletions(-) [+] |
line wrap: on
line diff
--- a/ChangeLog Wed Aug 25 17:13:03 2010 +0100 +++ b/ChangeLog Fri Aug 27 14:50:02 2010 -0400 @@ -1,3 +1,10 @@ +2010-08-27 Deepak Bhole <dbhole@redhat.com> + + Fixes rhbz#560193 + * netx/net/sourceforge/jnlp/runtime/JNLPClassLoader.java + (activateJars): Process nested jar only if size > 0 bytes. + * NEWS: Updated. + 2010-07-30 Andrew John Hughes <ahughes@redhat.com> * Makefile.am: Add patch below.
--- a/NEWS Wed Aug 25 17:13:03 2010 +0100 +++ b/NEWS Fri Aug 27 14:50:02 2010 -0400 @@ -9,6 +9,8 @@ - Run programs that inherit main(String[]) in their main-class - Run JNLP files that use 1.6 as the spec version - RH601281: Possible NullPointerException in splash screen code +* Plugin + - RH560193: Fix ziperror when applet jar contained another 0-byte jar New in release 1.8.1 (2010-07-28):
--- a/netx/net/sourceforge/jnlp/runtime/JNLPClassLoader.java Wed Aug 25 17:13:03 2010 +0100 +++ b/netx/net/sourceforge/jnlp/runtime/JNLPClassLoader.java Fri Aug 27 14:50:02 2010 -0400 @@ -638,13 +638,20 @@ byte[] bytes = new byte[1024]; int read = is.read(bytes); + int fileSize = read; while (read > 0) { extractedJar.write(bytes, 0, read); read = is.read(bytes); + fileSize += read; } is.close(); extractedJar.close(); + + // 0 byte file? skip + if (fileSize <= 0) { + continue; + } JarSigner signer = new JarSigner(); signer.verifyJar(extractedJarLocation);