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

Fix timeout flag behavior #826

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

elliotwutingfeng
Copy link

Fix timeout flag behavior for 0 value, negative value, empty value, and non-numeric value. Add timeout flag description to README.

Example

0 or negative values

-t0 -t-42 -> timeout of 0s (i.e. timeout disabled)

Empty or non-numeric values

-t -t' ' -ta1 -t1a -> reject timeout value as invalid, and hence fallback to default timeout of 120s

Relevant issues

Fixes #804

Contributor checklist
  • Provide tests for the changes (unless documentation-only)
  • Documented any new features, CLI switches, etc. (if applicable)
    • Server --help output
    • README.md
    • doc/http-server.1 (use the same format as other entries)
  • The pull request is being made against the master branch
Maintainer checklist
  • Assign a version triage tag
  • Approve tests if applicable

@github-actions
Copy link

github-actions bot commented Aug 3, 2023

This pull request has been inactive for 360 days

@github-actions github-actions bot added the stale label Aug 3, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Setting -t flag to 0 leaves timeout as default value of 120 seconds instead of disabling the timeout
1 participant