[RFC] Fix IndexOutOfBoundException because of corrupted entry in recently_used file
Thomas Meyer
thomas at m3y3r.de
Thu Apr 5 08:17:47 PDT 2012
Am Donnerstag, den 05.04.2012, 15:30 +0200 schrieb Thomas Meyer:
> > > --- a/netx/net/sourceforge/jnlp/cache/CacheLRUWrapper.java Wed Mar 28 12:08:10 2012 +0200
> > > +++ b/netx/net/sourceforge/jnlp/cache/CacheLRUWrapper.java Wed Apr 04 16:48:09 2012 +0200
> > > @@ -107,6 +107,49 @@
> > > */
> > > public synchronized void load() {
> > > cacheOrder.load();
> > > +
> > > + /*
> > > + * clean up possibly corrupted entries
> > > + */
> > It is interesting to see how many times is checkData called during single jar run.. I counted
> > 10executions.... But fixing this is definitely work for different patch.
>
> yeah, I also noticed this. maybe this can be reduced a bit. see below
> comment for getCacheFile(). but as the recently_used file could be
> corrupted by another jvm process (etc.), we need to check this on every
> load.
>
maybe the attached patch helps here?
with kind regards
thomas
-------------- next part --------------
A non-text attachment was scrubbed...
Name: reduce-number-of-loads-and-stores.patch
Type: text/x-patch
Size: 2642 bytes
Desc: not available
Url : http://mail.openjdk.java.net/pipermail/distro-pkg-dev/attachments/20120405/29783949/reduce-number-of-loads-and-stores.patch
More information about the distro-pkg-dev
mailing list