Skip to content

Commit

Permalink
Fix munmap output
Browse files Browse the repository at this point in the history
The file size was not being stored in the runs array, just print the
file_size from function args.

Signed-off-by: Eric B Munson <[email protected]>
  • Loading branch information
khers committed May 5, 2022
1 parent e93e6c4 commit f90cd5b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion new_lebench.c
Original file line number Diff line number Diff line change
Expand Up @@ -1386,7 +1386,7 @@ static void munmap_bench(size_t file_size)
for (i = 0; i < LOOP; i++)
{
calc_diff(&diff, &runs[i].end, &runs[i].start);
fprintf(fp, "%d,%ld,%ld.%09ld\n", i, runs[i].size, diff.tv_sec, diff.tv_nsec);
fprintf(fp, "%d,%ld,%ld.%09ld\n", i, file_size, diff.tv_sec, diff.tv_nsec);
}

munmap(runs, sizeof(struct Record) * LOOP);
Expand Down

0 comments on commit f90cd5b

Please sign in to comment.