fix: uint cant be negative..
This commit is contained in:
@@ -2129,9 +2129,11 @@ static int CmdT55xxChkPwds(const char *Cmd) {
|
|||||||
uint16_t keycount = 0;
|
uint16_t keycount = 0;
|
||||||
|
|
||||||
int res = loadFileDICTIONARY_safe(filename, (void**) &keyBlock, 4, &keycount);
|
int res = loadFileDICTIONARY_safe(filename, (void**) &keyBlock, 4, &keycount);
|
||||||
if (res != PM3_SUCCESS || keycount <= 0 || keyBlock == NULL) {
|
if (res != PM3_SUCCESS || keycount == 0 || keyBlock == NULL) {
|
||||||
PrintAndLogEx(WARNING, "No keys found in file");
|
PrintAndLogEx(WARNING, "No keys found in file");
|
||||||
if (keyBlock != NULL) free(keyBlock);
|
if (keyBlock != NULL)
|
||||||
|
free(keyBlock);
|
||||||
|
|
||||||
return PM3_ESOFT;
|
return PM3_ESOFT;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user