]> granicus.if.org Git - esp-idf/commit
nvs_flash: delete all duplicate entries in a page while loading
authorIvan Grokhotkov <ivan@espressif.com>
Mon, 31 Oct 2016 13:10:47 +0000 (21:10 +0800)
committerIvan Grokhotkov <ivan@espressif.com>
Mon, 31 Oct 2016 13:10:47 +0000 (21:10 +0800)
commitabea6c50f15f74c43f467a1179166ad031443b0a
tree5133916495c1f56ba856dbbcb792ccb40368334e
parentd9cdc7de5811a450919518b5ea8d6a8edd0a960f
nvs_flash: delete all duplicate entries in a page while loading

Due to previous flash write bug it was possible to create multiple duplicate entries in a single page.
Recovery logic detected that case and bailed out with an assert.
This change adds graceful recovery from this condition.
Tests included.
components/nvs_flash/src/nvs_page.cpp
components/nvs_flash/test/test_nvs.cpp