mirror of
https://github.com/RfidResearchGroup/proxmark3.git
synced 2025-08-21 13:53:55 -07:00
fix compiler warnings
This commit is contained in:
parent
6630f3724b
commit
967550d828
1 changed files with 6 additions and 3 deletions
|
@ -3293,16 +3293,19 @@ static int CmdHF14AMfuOtpTearoff(const char *Cmd) {
|
||||||
|
|
||||||
lock_on = true;
|
lock_on = true;
|
||||||
|
|
||||||
if ((phase_begin_clear == -1) && (bitcount32(*(uint32_t *)pre) > bitcount32(*(uint32_t *)post)))
|
uint32_t post32 = bytes_to_num(post, 4);
|
||||||
|
uint32_t pre32 = bytes_to_num(pre, 4);
|
||||||
|
|
||||||
|
if ((phase_begin_clear == -1) && (bitcount32(pre32) > bitcount32(post32)))
|
||||||
phase_begin_clear = current;
|
phase_begin_clear = current;
|
||||||
|
|
||||||
if ((phase_begin_clear > -1) && (phase_end_clear == -1) && (bitcount32(*(uint32_t *)post) == 0))
|
if ((phase_begin_clear > -1) && (phase_end_clear == -1) && (bitcount32(post32) == 0))
|
||||||
phase_end_clear = current;
|
phase_end_clear = current;
|
||||||
|
|
||||||
if ((current == start) && (phase_end_clear > -1))
|
if ((current == start) && (phase_end_clear > -1))
|
||||||
skip_phase1 = true;
|
skip_phase1 = true;
|
||||||
// new write phase must be atleast 100us later..
|
// new write phase must be atleast 100us later..
|
||||||
if (((bitcount32(*(uint32_t *)pre) == 0) || (phase_end_clear > -1)) && (phase_begin_newwr == -1) && (bitcount32(*(uint32_t *)post) != 0) && (skip_phase1 || (current > (phase_end_clear + 100))))
|
if (((bitcount32(pre32) == 0) || (phase_end_clear > -1)) && (phase_begin_newwr == -1) && (bitcount32(post32) != 0) && (skip_phase1 || (current > (phase_end_clear + 100))))
|
||||||
phase_begin_newwr = current;
|
phase_begin_newwr = current;
|
||||||
|
|
||||||
if ((phase_begin_newwr > -1) && (phase_end_newwr == -1) && (memcmp(post, teardata, sizeof(teardata)) == 0))
|
if ((phase_begin_newwr > -1) && (phase_end_newwr == -1) && (memcmp(post, teardata, sizeof(teardata)) == 0))
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue