this is the comment I wrote to myself for SMSQmulator in this respect:

Patch for badly constructed drives, like those built by qxltools. These drives do NOT have cluster entries for the FAT(!!!!). They just indicate the number of sectors taken by the FAT. I presume that it can then be presumed that the FAT's sectors are all contiguous and start at sector 0.

Treated like this:

int nbrOfSectorsInMap=firstSector.getShort(WinDrive.QWA_SCTM)&0xffff;
// that many sectors are supposed to be in the fat

int temp=nbrOfSectorsInMap/(firstSector.getShort(WinDrive.QWA_SCTG)&0xffff);
if (nbrOfSectorsInMap % (firstSector.getShort(WinDrive.QWA_SCTG)&0xffff) !=0)
  temp++;   // these are the number of clusters needed to hold the map

if (temp!=this.fatClusterChain.size())  (...)
// if they both agree, all is ok, I have a valid drive map



Can you give me an example of how to reproduce the problem(s) you are
seeing? I've just created a 20 MB qxl.win with no problems. (So far!)

Unfortunately not right now, and my memory is vague. I think that
all issues were gone with 16 MB and less. My next image size step
was probably 32 MB, not just 20 MB.

It could be, that just recompiling the latest qxltool source with an
up-to-date compiler and library makes the issues disappear.

I've created a couple of qxl.win files (at coffee time - I'm working) and checked them with my own QXLWin program. The headers looks strange to me:

On the 4 MB I see these dubious fields:

* Sectors per map = 21
* NumberĀ  of maps = 100
* Root directory length = 58

On the 20 MB I see these dubious fields:

* Sectors per map = $A1 (161)
* NumberĀ  of maps = 100
* Root directory length = 58

I've had a quick look at the definition of a QLWA header in the code and it appears slightly broken. Some of the fields I would think essential are not being used - sectors per block for example. That changes as the files grow bigger and might be related to your problems.

I'll see what I can do - there are still quite a few compilation warnings I need to get rid of first.


QL-Users Mailing List

Reply via email to