mirror of
https://github.com/RfidResearchGroup/proxmark3.git
synced 2025-08-20 21:33:47 -07:00
fix coverity CID 322227
This commit is contained in:
parent
089ec732a7
commit
9498a07262
1 changed files with 2 additions and 2 deletions
|
@ -676,16 +676,16 @@ int saveFileJSONroot(const char *preferredName, void *root, size_t flags, bool v
|
||||||
|
|
||||||
int res = json_dump_file(root, filename, flags);
|
int res = json_dump_file(root, filename, flags);
|
||||||
|
|
||||||
free(filename);
|
|
||||||
|
|
||||||
if ( res == 0 ) {
|
if ( res == 0 ) {
|
||||||
if (verbose) {
|
if (verbose) {
|
||||||
PrintAndLogEx(SUCCESS, "saved to json file " _YELLOW_("%s"), filename);
|
PrintAndLogEx(SUCCESS, "saved to json file " _YELLOW_("%s"), filename);
|
||||||
}
|
}
|
||||||
|
free(filename);
|
||||||
return PM3_SUCCESS;
|
return PM3_SUCCESS;
|
||||||
} else {
|
} else {
|
||||||
PrintAndLogEx(FAILED, "error: can't save the file: " _YELLOW_("%s"), filename);
|
PrintAndLogEx(FAILED, "error: can't save the file: " _YELLOW_("%s"), filename);
|
||||||
}
|
}
|
||||||
|
free(filename);
|
||||||
return PM3_EFILE;
|
return PM3_EFILE;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue