mirror of
https://github.com/RfidResearchGroup/proxmark3.git
synced 2025-08-23 06:35:38 -07:00
Fix styles
Run `make style`
This commit is contained in:
parent
f655391bd4
commit
62ccbc0a37
1 changed files with 15 additions and 17 deletions
|
@ -113,12 +113,12 @@ int demodGallagher(bool verbose) {
|
||||||
// bytes
|
// bytes
|
||||||
uint8_t arr[8] = {0};
|
uint8_t arr[8] = {0};
|
||||||
for (int i = 0, pos = 0; i < ARRAYLEN(arr); i++) {
|
for (int i = 0, pos = 0; i < ARRAYLEN(arr); i++) {
|
||||||
pos = 16 + 9*i;
|
pos = 16 + (9 * i);
|
||||||
arr[i] = bytebits_to_byte(DemodBuffer + pos, 8);
|
arr[i] = bytebits_to_byte(DemodBuffer + pos, 8);
|
||||||
}
|
}
|
||||||
|
|
||||||
// crc
|
// crc
|
||||||
uint8_t crc = bytebits_to_byte(DemodBuffer + 16 + 9*8, 8);
|
uint8_t crc = bytebits_to_byte(DemodBuffer + 16 + (9 * 8), 8);
|
||||||
uint8_t calc_crc = CRC8Cardx(arr, ARRAYLEN(arr));
|
uint8_t calc_crc = CRC8Cardx(arr, ARRAYLEN(arr));
|
||||||
|
|
||||||
PrintAndLogEx(INFO, " Before: %s", sprint_hex(arr, 8));
|
PrintAndLogEx(INFO, " Before: %s", sprint_hex(arr, 8));
|
||||||
|
@ -275,8 +275,7 @@ static int CmdGallagherClone(const char *Cmd) {
|
||||||
PrintAndLogEx(FAILED, "Must specify either raw data to clone, or rc/fc/cn/il");
|
PrintAndLogEx(FAILED, "Must specify either raw data to clone, or rc/fc/cn/il");
|
||||||
return PM3_EINVARG;
|
return PM3_EINVARG;
|
||||||
}
|
}
|
||||||
}
|
} else {
|
||||||
else {
|
|
||||||
// --raw and --rc/fc/cn/il are mutually exclusive
|
// --raw and --rc/fc/cn/il are mutually exclusive
|
||||||
if (use_raw) {
|
if (use_raw) {
|
||||||
PrintAndLogEx(FAILED, "Can't specify both raw and rc/fc/cn/il at the same time");
|
PrintAndLogEx(FAILED, "Can't specify both raw and rc/fc/cn/il at the same time");
|
||||||
|
@ -311,8 +310,7 @@ static int CmdGallagherClone(const char *Cmd) {
|
||||||
for (uint8_t i = 1; i < ARRAYLEN(blocks); i++) {
|
for (uint8_t i = 1; i < ARRAYLEN(blocks); i++) {
|
||||||
blocks[i] = bytes_to_num(raw + ((i - 1) * 4), sizeof(uint32_t));
|
blocks[i] = bytes_to_num(raw + ((i - 1) * 4), sizeof(uint32_t));
|
||||||
}
|
}
|
||||||
}
|
} else {
|
||||||
else {
|
|
||||||
// fill blocks 1 to 3 with Gallagher data
|
// fill blocks 1 to 3 with Gallagher data
|
||||||
createBlocks(blocks + 1, region_code, facility_code, card_number, issue_level);
|
createBlocks(blocks + 1, region_code, facility_code, card_number, issue_level);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue