Go Down

Topic: SdFile::contiguousRange() faile when filesize is multiple of cluster size (Read 488 times) previous topic - next topic


I have a file that's 262144 bytes (256k == 0x40000 bytes).
File was created with SdFile::createContiguous().

Note that my file is EXACTLY 4 clusters (4x 64k)

SdFile::contiguousRange() will return false for this file.
If I create the file with size of 256k+1 or 256k-1 bytes, contiguousRange() returns true.

Looks like the culprit is that EOC detection is done AFTER the (next != (c + 1)) check.

Anyone experience this?

Go Up