fix CID #405231 - resource leak

This commit is contained in:
iceman1001 2023-03-04 20:14:09 +01:00
parent b3652c28be
commit 173841b533

View file

@ -1481,6 +1481,9 @@ static int acquire_nonces(uint8_t blockNo, uint8_t keyType, uint8_t *key, uint8_
if (got_match == false) {
PrintAndLogEx(FAILED, "No match for the First_Byte_Sum (%u), is the card a genuine MFC Ev1? ", first_byte_Sum);
if (nonce_file_write) {
fclose(fnonces);
}
return PM3_EWRONGANSWER;
}