diff options
author | Daniel Palmer <danieruru@gmail.com> | 2014-05-20 16:33:41 +0900 |
---|---|---|
committer | Daniel Palmer <danieruru@gmail.com> | 2014-05-20 16:33:41 +0900 |
commit | f71a545ce9bd0835ddd2382f4553fcdc2407d72b (patch) | |
tree | 62e409473994cab551b8d5917e0ba2ce6a3ed66b /flash.c | |
parent | 8e10ce6cc4810debb06672eb072b7a33e173c816 (diff) |
- Fix the mhash cmake file for Debian/armhf
- Proposed single line solution to handle flash struct changes
Diffstat (limited to 'flash.c')
-rw-r--r-- | flash.c | 7 |
1 files changed, 7 insertions, 0 deletions
@@ -306,6 +306,13 @@ hdrlengthok: static int readUserBlock(FlashStruct *mem) { + // put the default values into the the struct; + // what should happen here is that if we load + // a smaller struct from disk it will replace + // the top part and leave the defaults for newly + // added values at the end + initFlashValues(mem); + // try to unfreeze the main file if (persistence_unfreeze(MAINFILE, mem, sizeof(*mem), 0)) { return sizeof(*mem); |