[kaffe] Problem: gcMalloc: Assertion `fidx < nrTypes && size != 0' failed.

Timothy Stack stack at cs.utah.edu
Thu Apr 25 08:01:23 PDT 2002

> But, i also tried it in janosvm's newer jar file code, but
> it doesn't like the format of the file, the size of the central
> directory didn't match the number of entries.  This may or may not be a
> problem for kaffe as well.  What did you use to make the jar file?

ops, ignore this, i made a mistake...

> Anyways, java_util_zip_ZipFile_getZipData0 in
> libraries/clib/native/ZipFile.c should prolly check for a zero length file
> before calling getDataJarFile().

This should do the trick as well as adding a check in getDataJarFile() so
findInJar and other things don't fail.  It should probably just return a
small chunk of malloc'ed memory...

Also, is there a good reason why we don't allow zero-length mallocs?

> > Thanks & regards,
> > Santosh

tim stack

More information about the kaffe mailing list