Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[BUG] Order of set options. #2869

Open
mycrl opened this issue Feb 11, 2024 · 2 comments
Open

[BUG] Order of set options. #2869

mycrl opened this issue Feb 11, 2024 · 2 comments
Labels
[docs] Area: Improvements or additions to documentation help wanted Indicates that a maintainer wants help on an issue or pull request Type: Maintenance Work required to maintain or clean up the code
Milestone

Comments

@mycrl
Copy link

mycrl commented Feb 11, 2024

Describe the bug
The order in which the options are set affects whether the other options are set successfully.

To Reproduce

int latency = 20;
srt_setsockflag(sock, SRTO_RCVLATENCY, &latency, sizeof(int));
srt_setsockflag(sock, SRTO_TRANSTYPE, &SRTT_LIVE, sizeof(SRTT_LIVE));

RCVLATENCY still defaults to 120ms.

Expected behavior

Hopefully the RCVLATENCY value has been set to 20ms.

Desktop (please provide the following information):

  • OS: Windows, Linux, Macos
  • SRT Version / commit ID: 1.5.3

Additional context

int latency = 20;
srt_setsockflag(sock, SRTO_TRANSTYPE, &SRTT_LIVE, sizeof(SRTT_LIVE));
srt_setsockflag(sock, SRTO_RCVLATENCY, &latency, sizeof(int));

If you first Set real-time mode and then set latency, it will be set successfully.

I don't think the settings of the setup's options should be related to the order, it's not intuitive and it's not developer friendly.

@mycrl mycrl added the Type: Bug Indicates an unexpected problem or unintended behavior label Feb 11, 2024
@ethouris
Copy link
Collaborator

@maxsharabayko I think we need a list of options that are set to their defaults for particular mode in the description. Currently this is only mentioned at the options that are being set, and also not all - SRTO_LATENCY isn't among them.

@maxsharabayko
Copy link
Collaborator

There is also a dependency between SRTO_RCVBUF and SRTO_FC (#700).

@maxsharabayko maxsharabayko added Type: Maintenance Work required to maintain or clean up the code [docs] Area: Improvements or additions to documentation and removed Type: Bug Indicates an unexpected problem or unintended behavior labels Feb 12, 2024
@maxsharabayko maxsharabayko added this to the Backlog milestone Feb 12, 2024
@maxsharabayko maxsharabayko added the help wanted Indicates that a maintainer wants help on an issue or pull request label Feb 12, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
[docs] Area: Improvements or additions to documentation help wanted Indicates that a maintainer wants help on an issue or pull request Type: Maintenance Work required to maintain or clean up the code
Projects
None yet
Development

No branches or pull requests

3 participants