mirror of
https://github.com/RfidResearchGroup/proxmark3.git
synced 2025-03-19 19:38:52 +08:00
reuse MAX macro
This commit is contained in:
parent
c2092ee2ed
commit
e67215fe49
1 changed files with 1 additions and 6 deletions
|
@ -48,11 +48,6 @@
|
|||
#define MIFARE_2K_MAXSECTOR 32
|
||||
#define MIFARE_4K_MAXSECTOR 40
|
||||
|
||||
/* On some platforms, max() may already be defined */
|
||||
#ifndef max
|
||||
#define max(a, b) ((a) > (b) ? (a) : (b))
|
||||
#endif
|
||||
|
||||
static int CmdHelp(const char *Cmd);
|
||||
|
||||
/*
|
||||
|
@ -1243,7 +1238,7 @@ static int CmdHF14AMfNested(const char *Cmd) { //TODO: single mode broken? can't
|
|||
if (singleSector) {
|
||||
uint8_t MinSectorsCnt = 0;
|
||||
// find a MIFARE type that can accommodate the provided block number
|
||||
uint8_t s = max(mfSectorNum(trgBlockNo), mfSectorNum(blockNo));
|
||||
uint8_t s = MAX(mfSectorNum(trgBlockNo), mfSectorNum(blockNo));
|
||||
if (s < MIFARE_MINI_MAXSECTOR) {
|
||||
MinSectorsCnt = MIFARE_MINI_MAXSECTOR;
|
||||
} else if (s < MIFARE_1K_MAXSECTOR) {
|
||||
|
|
Loading…
Add table
Reference in a new issue