Consistency with do..while blocks usage

This commit is contained in:
Willy-JL
2023-12-13 01:36:19 +00:00
parent 4c6eb896ed
commit a6a749b76f
3 changed files with 3 additions and 3 deletions

View File

@@ -204,7 +204,7 @@ static bool microel_parse(const NfcDevice* device, FuriString* parsed_data) {
mf_classic_get_sector_trailer_by_sector(data, verify_sector);
uint64_t key = nfc_util_bytes2num(sec_tr->key_a.data, 6);
uint64_t key_for_check_from_array = nfc_util_bytes2num(keyA, KEY_LENGTH);
if(key != key_for_check_from_array) return false;
if(key != key_for_check_from_array) break;
//Get credit in block number 8
const uint8_t* temp_ptr = data->block[4].data;

View File

@@ -147,7 +147,7 @@ static bool mizip_parse(const NfcDevice* device, FuriString* parsed_data) {
MfClassicSectorTrailer* sec_tr =
mf_classic_get_sector_trailer_by_sector(data, verify_sector);
uint64_t key = nfc_util_bytes2num(sec_tr->key_b.data, 6);
if(key != mizip_1k_keys[verify_sector].b) return false;
if(key != mizip_1k_keys[verify_sector].b) break;
//Get UID
uint8_t uid[UID_LENGTH];

View File

@@ -111,7 +111,7 @@ static bool two_cities_parse(const NfcDevice* device, FuriString* parsed_data) {
// Verify key
MfClassicSectorTrailer* sec_tr = mf_classic_get_sector_trailer_by_sector(data, 4);
uint64_t key = nfc_util_bytes2num(sec_tr->key_a.data, 6);
if(key != two_cities_4k_keys[4].a) return false;
if(key != two_cities_4k_keys[4].a) break;
// =====
// PLANTAIN