mirror of
https://github.com/RfidResearchGroup/proxmark3.git
synced 2025-08-14 18:48:13 -07:00
cppcheck nullPointerOutOfMemory
This commit is contained in:
parent
e42932738e
commit
ad84875afd
44 changed files with 314 additions and 5 deletions
|
@ -277,6 +277,10 @@ int main(int argc, char *argv[]) {
|
|||
uint64_t stop_time = time(NULL);
|
||||
for (int i = 0; i < thread_count; ++i) {
|
||||
struct thread_args *a = calloc(1, sizeof(struct thread_args));
|
||||
if (a == NULL) {
|
||||
fprintf(stderr, "Failed to allocate memory for thread arguments\n");
|
||||
exit(EXIT_FAILURE);
|
||||
}
|
||||
a->thread = i;
|
||||
a->idx = i;
|
||||
a->starttime = start_time;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue