Skip to content

Commit ce52dbc

Browse files
committed
fixed is_erased variable scope
1 parent 6d6368a commit ce52dbc

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/storage/storage.nrf51.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,8 @@
44
#include "nrf_delay.h"
55
#include "feature_config.h"
66

7+
bool is_erased = true;
8+
79
FS_REGISTER_CFG(fs_config_t fs_config) =
810
{
911
.callback = fs_evt_handler, // Function for event callbacks.
@@ -81,8 +83,6 @@ void storage_checksum_check(){
8183
// read 4 more to capcure checksum
8284
storage_read(0x00, data, length + 4);
8385

84-
bool is_erased = true;
85-
8686
for(uint32_t i = 0; i < length; i++){
8787
if(data[i] != 0xFF){
8888
is_erased = false;

0 commit comments

Comments
 (0)