mirror of
				https://github.com/eledio-devices/thirdparty-littlefs.git
				synced 2025-10-31 08:42:40 +01:00 
			
		
		
		
	Merge pull request #612 from tniessen/patch-1
Always zero rambd buffer before first use
This commit is contained in:
		| @@ -36,6 +36,8 @@ int lfs_rambd_createcfg(const struct lfs_config *cfg, | |||||||
|     if (bd->cfg->erase_value != -1) { |     if (bd->cfg->erase_value != -1) { | ||||||
|         memset(bd->buffer, bd->cfg->erase_value, |         memset(bd->buffer, bd->cfg->erase_value, | ||||||
|                 cfg->block_size * cfg->block_count); |                 cfg->block_size * cfg->block_count); | ||||||
|  |     } else { | ||||||
|  |         memset(bd->buffer, 0, cfg->block_size * cfg->block_count); | ||||||
|     } |     } | ||||||
|  |  | ||||||
|     LFS_RAMBD_TRACE("lfs_rambd_createcfg -> %d", 0); |     LFS_RAMBD_TRACE("lfs_rambd_createcfg -> %d", 0); | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user