Skip to content

Commit

Permalink
Fix bug #64637 ("iperf -n 1000 -r" does not work)
Browse files Browse the repository at this point in the history
  • Loading branch information
goldsimon committed Sep 27, 2023
1 parent 4e6dd9c commit 3792075
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/apps/lwiperf/lwiperf.c
Original file line number Diff line number Diff line change
Expand Up @@ -302,7 +302,7 @@ lwiperf_tcp_client_send_more(lwiperf_state_tcp_t *conn)
/* this session is byte-limited */
u32_t amount_bytes = lwip_htonl(conn->settings.amount);
/* @todo: this can send up to 1*MSS more than requested... */
if (amount_bytes >= conn->bytes_transferred) {
if (conn->bytes_transferred >= amount_bytes) {
/* all requested bytes transferred -> close the connection */
lwiperf_tcp_close(conn, LWIPERF_TCP_DONE_CLIENT);
return ERR_OK;
Expand Down

0 comments on commit 3792075

Please sign in to comment.