summary |
shortlog |
log |
commit | commitdiff |
tree
raw |
patch |
inline | side by side (from parent 1:
1ece662)
* Fix typo in hf mf csave help
* Fix gcc 7 warning: '~' on an expression of type bool [-Wbool-operation], use logical ! not instead of ~
* Fix gcc 7 warning: ‘memset’ used with length equal to number of elements without multiplication by element size [-Wmemset-elt-size]
* Fix gcc 7 warning: warning: duplicate ‘const’ declaration specifier [-Wduplicate-decl-specifier]
if (param_getchar(Cmd, 0) == 'h') {\r
PrintAndLog("It saves `magic Chinese` card dump into the file `filename.eml` or `cardID.eml`");\r
PrintAndLog("or into emulator memory (option `e`). 4K card: (option `4`)");\r
if (param_getchar(Cmd, 0) == 'h') {\r
PrintAndLog("It saves `magic Chinese` card dump into the file `filename.eml` or `cardID.eml`");\r
PrintAndLog("or into emulator memory (option `e`). 4K card: (option `4`)");\r
- PrintAndLog("Usage: hf mf esave [file name w/o `.eml`][e][4]");\r
- PrintAndLog("Sample: hf mf esave ");\r
- PrintAndLog(" hf mf esave filename");\r
- PrintAndLog(" hf mf esave e");\r
- PrintAndLog(" hf mf esave 4");\r
- PrintAndLog(" hf mf esave filename 4");\r
- PrintAndLog(" hf mf esave e 4");\r
+ PrintAndLog("Usage: hf mf csave [file name w/o `.eml`][e][4]");\r
+ PrintAndLog("Sample: hf mf csave ");\r
+ PrintAndLog(" hf mf csave filename");\r
+ PrintAndLog(" hf mf csave e");\r
+ PrintAndLog(" hf mf csave 4");\r
+ PrintAndLog(" hf mf csave filename 4");\r
+ PrintAndLog(" hf mf csave e 4");\r
char tmp2[20];
int phaseoff;
high = low = 0;
char tmp2[20];
int phaseoff;
high = low = 0;
- memset(tmpbuff, 0, MAX_GRAPH_TRACE_LEN / 64);
+ memset(tmpbuff, 0, sizeof(tmpbuff));
// get user entry if any
sscanf(Cmd, "%i %i", &clk, &invert);
// get user entry if any
sscanf(Cmd, "%i %i", &clk, &invert);
// }
#endif
// add the even state bits
// }
#endif
// add the even state bits
- const bitslice_t const *restrict bitsliced_even_state = bitsliced_even_states[block_idx];
+ const bitslice_t *restrict bitsliced_even_state = bitsliced_even_states[block_idx];
for(uint32_t state_idx = 1; state_idx < STATE_SIZE; state_idx += 2) {
state_p[state_idx] = bitsliced_even_state[state_idx/2];
}
for(uint32_t state_idx = 1; state_idx < STATE_SIZE; state_idx += 2) {
state_p[state_idx] = bitsliced_even_state[state_idx/2];
}
bool r6 = r >> 1 & 0x1;
bool r7 = r & 0x1;
bool r6 = r >> 1 & 0x1;
bool r7 = r & 0x1;
- bool z0 = (r0 & r2) ^ (r1 & ~r3) ^ (r2 | r4);
+ bool z0 = (r0 & r2) ^ (r1 & !r3) ^ (r2 | r4);
bool z1 = (r0 | r2) ^ ( r5 | r7) ^ r1 ^ r6 ^ x ^ y;
bool z1 = (r0 | r2) ^ ( r5 | r7) ^ r1 ^ r6 ^ x ^ y;
- bool z2 = (r3 & ~r5) ^ (r4 & r6 ) ^ r7 ^ x;
+ bool z2 = (r3 & !r5) ^ (r4 & r6 ) ^ r7 ^ x;
// The three bitz z0.. z1 are packed into a uint8_t:
// 00000ZZZ
// The three bitz z0.. z1 are packed into a uint8_t:
// 00000ZZZ