Skip to content

Commit

Permalink
Remove fsync(2) call after every write to a receiving --file. (esnet#…
Browse files Browse the repository at this point in the history
…1176)

This removes a performance pessimization that wasn't really
needed in the first place.

Fixes esnet#1159.
  • Loading branch information
bmah888 authored and hanvari committed Jul 3, 2021
1 parent 14f1379 commit 1e697e9
Showing 1 changed file with 0 additions and 1 deletion.
1 change: 0 additions & 1 deletion src/iperf_api.c
Original file line number Diff line number Diff line change
Expand Up @@ -4277,7 +4277,6 @@ diskfile_recv(struct iperf_stream *sp)
r = sp->rcv2(sp);
if (r > 0) {
(void) write(sp->diskfile_fd, sp->buffer, r);
(void) fsync(sp->diskfile_fd);
}
return r;
}
Expand Down

0 comments on commit 1e697e9

Please sign in to comment.