www.emsdn.com
Class Profile: Home »» Development [Development] under "Development" »»» PR 30454 Fix bootstrap on a couple of targets, empty "zip" file in class path can cause le

PR 30454 Fix bootstrap on a couple of targets, empty "zip" file in class path can cause le


Hi,
The problem here is that empty "zip" files in the classpath would
cause leakage of file streams which meant after a while, we hit the
limit of opened files. So when we try to open a class file, we would
fail.
This patch closes the file streams which are not referenced anywhere
after the call to opendir_in_zip because of a check failed.
K? Bootstrapped on powerpc-darwin with an open file limit of 256. The
testsuite is running right now and will be done later tonight but
getting the bootstrap up and working is important.
Thanks,
Andrew Pinski
* jcf-io.c (opendir_in_zip): Close the file if there is an error
in the zip file.


No. 1# | By Developer Tags User at [2008-5-6] | size: 426 bytes

"Andrew" == Andrew Pinski <pinskia (AT) gmail (DOT) comwrites:

AndrewThe problem here is that empty "zip" files in the classpath
Andrewwould cause leakage of file streams which meant after a while,
Andrewwe hit the limit of opened files.

Nice catch, thanks.

AndrewK?

I think we should free 'zipf' in the 'return NULL' cases.
with that change.

Tom

No. 1# | By Developer Tags User at [2008-5-6] | size: 721 bytes

Tue, 2007-01-23 at 08:40 -0700, Tom Tromey wrote:
"Andrew" == Andrew Pinski <pinskia (AT) gmail (DOT) comwrites:

AndrewThe problem here is that empty "zip" files in the classpath
Andrewwould cause leakage of file streams which meant after a while,
Andrewwe hit the limit of opened files.

Nice catch, thanks.

AndrewK?

I think we should free 'zipf' in the 'return NULL' cases.
with that change.

And this is what I applied.

Thanks,
Andrew Pinski

2007-01-23 Andrew Pinski <pinskia (AT) gmail (DOT) com>

PR java/30454
* jcf-io.c (opendir_in_zip): Close the file
and free zipf before returning after an error.



Development Hot!

Development New!


Copyright © 2008 www.emsdn.com • All rights reserved • CMS Theme by www.emsdn.com - 0.219