[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[MiNT] Small bug in fatfs.c?



Hi!
While I was browsing through the FAT32 handler in order to check my 
understanding of special cluster numbers (end of chain, bad cluster etc), I 
came across what may be a bug.  In fatfs.c, it appears that the MAXCL() macro 
is *supposed* to return the maximum cluster number; for example, the test for 
valid cluster number is:

# define FAT_VALID32(cl, dev)	(((cl) >= MINCL (dev)) && ((cl) <= MAXCL (dev)))

In fact, MAXCL() appears to return maxcl, which has been set to (numcl+2), 
which [I think] is the maximum cluster number + 1.

My apologies if I've missed something obvious in all this ...

Roger Burrows