From b5635a6407fcc84b053e73d6e858ea95ca173258 Mon Sep 17 00:00:00 2001 From: Marek Pieta Date: Tue, 4 Jul 2023 09:44:15 +0200 Subject: [PATCH] tests: fast_pair: Ensure reset in progress flag is deleted Change ensures that reset in progress flag is deleted during the Fast Pair factory reset operation. Jira: NCSDK-20219 Signed-off-by: Marek Pieta --- .../storage/factory_reset/src/main.c | 29 ------------------- 1 file changed, 29 deletions(-) diff --git a/tests/subsys/bluetooth/fast_pair/storage/factory_reset/src/main.c b/tests/subsys/bluetooth/fast_pair/storage/factory_reset/src/main.c index ed358bd00701..2f3f45d3b984 100644 --- a/tests/subsys/bluetooth/fast_pair/storage/factory_reset/src/main.c +++ b/tests/subsys/bluetooth/fast_pair/storage/factory_reset/src/main.c @@ -182,35 +182,6 @@ static int fp_settings_data_validate_empty_cb(const char *key, size_t len, setti return 0; } - if (!strncmp(key, SETTINGS_RESET_IN_PROGRESS_FULL_NAME, - sizeof(SETTINGS_RESET_IN_PROGRESS_FULL_NAME))) { - int rc; - bool reset_in_progress; - - if (len != sizeof(reset_in_progress)) { - *err = -EINVAL; - return *err; - } - - rc = read_cb(cb_arg, &reset_in_progress, len); - if (rc < 0) { - *err = rc; - return *err; - } - - if (rc != len) { - *err = -EINVAL; - return *err; - } - - if (reset_in_progress) { - *err = -EFAULT; - return *err; - } - - return 0; - } - *err = -EFAULT; return *err; }