[jboss-dev-forums] [Design the new POJO MicroContainer] - Re: Silent failover on broken jar file
adrian@jboss.org
do-not-reply at jboss.com
Wed Mar 12 09:39:21 EDT 2008
"alesj" wrote :
| While you can easily rename file, you probably cannot fix it.
| But how many .jar files did you see that were not actually jars, opposed to broken zips. ;-)
You mean besides directories being unpacked jars? ;-)
I guess we could add an extra check that tries to open the raw stream
and see whether it contains the magic PK at the start:
http://en.wikipedia.org/wiki/Magic_number_(programming)
If it does then throw an IOException about the broken archive.
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4135938#4135938
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4135938
More information about the jboss-dev-forums
mailing list