Changeset 0c348ec


Ignore:
Timestamp:
Mar 17, 2012 9:56:20 PM (8 years ago)
Author:
zzz <zzz@…>
Branches:
master
Children:
0a521b7
Parents:
df8bab6
Message:
  • FileUtil?: Better logging of weird unpack200 errors
File:
1 edited

Legend:

Unmodified
Added
Removed
  • core/java/src/net/i2p/util/FileUtil.java

    rdf8bab6 r0c348ec  
    148148                        ioe.printStackTrace();
    149149                        return false;
    150                     } catch (Exception e) {  // ClassNotFoundException but compiler not happy with that
    151                         System.err.println("ERROR: Error unpacking the zip entry (" + entry.getName() +
    152                                            "), your JVM does not support unpack200");
     150                    } catch (Exception e) {
     151                        // Oracle unpack() should throw an IOE but other problems can happen, e.g:
     152                        // java.lang.reflect.InvocationTargetException
     153                        // Caused by: java.util.zip.ZipException: duplicate entry: xxxxx
     154                        System.err.println("ERROR: Error extracting the zip entry (" + entry.getName() + ')');
     155                        e.printStackTrace();
    153156                        return false;
    154157                    } finally {
     
    262265     *         Will not throw ClassNotFoundException.
    263266     * @throws org.apache.harmony.pack200.Pack200Exception which is not an IOException
     267     * @throws java.lang.reflect.InvocationTargetException on duplicate zip entries in the packed jar
    264268     * @since 0.8.1
    265269     */
Note: See TracChangeset for help on using the changeset viewer.