mirror of
https://github.com/RfidResearchGroup/proxmark3.git
synced 2025-08-19 21:03:48 -07:00
FIX: GenerateFilename() return broken filename if no tag is detected.
This commit is contained in:
parent
45c20d62b8
commit
8e04df77ba
1 changed files with 2 additions and 1 deletions
|
@ -364,7 +364,8 @@ char * GenerateFilename(const char *prefix, const char *suffix){
|
||||||
int uidlen=0;
|
int uidlen=0;
|
||||||
char * fptr = malloc (sizeof (char) * (strlen(prefix) + strlen(suffix)) + sizeof(uid)*2 + 1);
|
char * fptr = malloc (sizeof (char) * (strlen(prefix) + strlen(suffix)) + sizeof(uid)*2 + 1);
|
||||||
|
|
||||||
if (!GetHFMF14AUID(uid, &uidlen)) {
|
GetHFMF14AUID(uid, &uidlen);
|
||||||
|
if (!uidlen) {
|
||||||
PrintAndLog("No tag found.");
|
PrintAndLog("No tag found.");
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue