Siraj Sherriff - 2007-04-26

Logged In: YES
user_id=1118589
Originator: YES

I did some more R&D on this problem. I ran into a problem with the functioning of DataFactory class. Here is what I found:

1. When DataFactory class is processing the .ec file, the line

final byte type = raf.readByte ();

is always returning type=1, since the code is processing a coverage data file.

2. In between at some point, raf.readByte() returns 0 instead of 1 and the code switches to process metadata file since type=0 indicates a metadata file.

3. Therafter, Metadata.readExternal(din) takes over and din.readInt() returns a very huge number which is well beyond the VM settings. When the code tries to initialize a HashMap with that huge number, it throws an out of memory error.

I am not sure why the type value switches to "0" during the coverage data file processing.