Fixed allocation bugs near the end of storage

Also added better testing specifically for these corner cases
around the end of storage
This commit is contained in:
Christopher Haster
2017-04-29 12:41:53 -05:00
parent 210b487325
commit a30142e0e1
3 changed files with 110 additions and 27 deletions

1
lfs.h
View File

@@ -195,6 +195,7 @@ typedef struct lfs {
lfs_size_t words; // number of 32-bit words that can fit in a block
lfs_block_t root[2];
lfs_dir_t *scratch;
lfs_file_t *files;
struct {