mynewt-nffs icon indicating copy to clipboard operation
mynewt-nffs copied to clipboard

Invalid inode cache in nffs_write_append()

Open yashi opened this issue 5 years ago • 0 comments

;; Even though README says we must report to Jira, I found that Jira is deprecated. So here I go.

nffs_write_append() gets a pointer to struct nffs_cache_inode as the first argument. Unfortunately, the function calls nffs_block_entry_reserve() as the first thing in the the function. Because nffs_block_entry_reserve() might invalidate the given cache in low memory situation, subsequent accesses to the cache must be protected by nffs_cache_inode_ensure().

yashi avatar Sep 10 '19 07:09 yashi