Skip to content

Conversation

@davidBar-On
Copy link
Contributor

  • Version of iperf3 (or development branch, such as master or
    3.1-STABLE) to which this pull request applies:
    master

  • Issues fixed (if any): none

  • Brief description of code changes (suitable for use as a commit message):

In case get_parameters() failure, send SERVER_ERROR state to the client, following by the error code (i_errno) set inside get_parameters (e.g. the IEUDPFILETRANSFER error in #1909).

This is actually a generalization of already existing mechanism for specific error codes. E.g., with this PR changes, PR #1684 can just set the IEMAXSERVERTESTDURATIONEXCEEDED error in get_parameters(), without adding sending SERVER_ERROR, etc. specifically for that error.

@manedurphy
Copy link
Contributor

I think I'd like to leverage this change for iperf/#1931 as well. I can validate the requested bit rate within get_parameters similar to how you validated the use of --file and --udp used together.

@bmah888 bmah888 self-assigned this Sep 19, 2025
@bmah888
Copy link
Contributor

bmah888 commented Sep 19, 2025

Thanks for the PR! I think this is the right way to solve the problem.

Intending to merge this after some testing.

Copy link
Contributor

@bmah888 bmah888 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks this looks good. Used the test cases for #1909 (in particular the mutually-exclusive --file and --udp) and noted that the error codes are propagated from the server back to the client. Noting that this improved behavior is only implemented on the server...the client gains the benefit whether or not it has this code change.

We have to be careful not to make changes to existing error codes, but as this code sequence existed already, we already had this requirement.

@bmah888 bmah888 merged commit 6b391d4 into esnet:master Sep 19, 2025
7 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants