Skip to content

Commit 2492633

Browse files
committed
n64tool: avoid writing random memory into DFS file
(cherry picked from commit 9779fbe)
1 parent 5d201c6 commit 2492633

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Diff for: tools/n64tool.c

+1-1
Original file line numberDiff line numberDiff line change
@@ -718,7 +718,7 @@ int main(int argc, char *argv[])
718718
toc.entry_size = SWAPLONG(toc.entry_size);
719719

720720
fseek(write_file, toc_offset, SEEK_SET);
721-
fwrite(&toc, 1, TOC_SIZE, write_file);
721+
fwrite(&toc, 1, sizeof(toc), write_file);
722722
}
723723

724724
/* Sync and close the output file */

0 commit comments

Comments
 (0)