From 0f2eaa316b8364da6db1d32142052040309ff96a Mon Sep 17 00:00:00 2001 From: douniwan5788 Date: Mon, 26 Aug 2024 21:45:06 +0800 Subject: [PATCH] fix: WITH_EM4x50 and WITH_EM4x70 in `lf search` --- client/src/cmdlf.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/client/src/cmdlf.c b/client/src/cmdlf.c index 4b6f10088..2f179a948 100644 --- a/client/src/cmdlf.c +++ b/client/src/cmdlf.c @@ -1553,7 +1553,7 @@ static bool check_chiptype(bool getDeviceData) { //check for em4x05/em4x69 chips first uint32_t word = 0; - if (em4x05_isblock0(&word)) { + if (IfPm3EM4x50() && em4x05_isblock0(&word)) { PrintAndLogEx(SUCCESS, "Chipset detection: " _GREEN_("EM4x05 / EM4x69")); PrintAndLogEx(HINT, "Hint: try " _YELLOW_("`lf em 4x05`") " commands"); retval = true; @@ -1570,7 +1570,7 @@ static bool check_chiptype(bool getDeviceData) { #if !defined ICOPYX // check for em4x50 chips - if (detect_4x50_block()) { + if (IfPm3EM4x50() && detect_4x50_block()) { PrintAndLogEx(SUCCESS, "Chipset detection: " _GREEN_("EM4x50")); PrintAndLogEx(HINT, "Hint: try " _YELLOW_("`lf em 4x50`") " commands"); retval = true; @@ -1578,7 +1578,7 @@ static bool check_chiptype(bool getDeviceData) { } // check for em4x70 chips - if (detect_4x70_block()) { + if (IfPm3EM4x70() && detect_4x70_block()) { PrintAndLogEx(SUCCESS, "Chipset detection: " _GREEN_("EM4x70")); PrintAndLogEx(HINT, "Hint: try " _YELLOW_("`lf em 4x70`") " commands"); retval = true;