Skip to content

Commit

Permalink
Fixed a non-init bug in identifier.c.
Browse files Browse the repository at this point in the history
  • Loading branch information
ax-6 committed Aug 3, 2024
1 parent 882b405 commit 834867e
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions aqvm/base/file/identifier/unix/identifier.c
Original file line number Diff line number Diff line change
Expand Up @@ -17,15 +17,15 @@ int AqvmBaseFileIdentifierUnix_GetIdentifier(const char* filename,
return -1;
}

struct stat* file_info;
struct stat file_info;

if (stat(filename, file_info) != 0) {
if (stat(filename, &file_info) != 0) {
// TODO
return -2;
}

identifier->st_dev = file_info->st_dev;
identifier->st_ino = file_info->st_ino;
identifier->st_dev = file_info.st_dev;
identifier->st_ino = file_info.st_ino;

return 0;
}
Expand Down

0 comments on commit 834867e

Please sign in to comment.