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 max limit for connect timeout #31

Merged
merged 1 commit into from
Jul 20, 2022
Merged

fix max limit for connect timeout #31

merged 1 commit into from
Jul 20, 2022

Conversation

tanmaykm
Copy link
Member

This adds an upper limit to the connect timeout value that can be specified,
to limit it to typemax(Clong) ÷ 1000. An ArgumentError is thrown if the
value is out of range.

This matches what libcurl expects here.

Originally reported by @manuelbb-upb at JuliaLang/Downloads.jl#193 and #23.

This adds an upper limit to the connect timeout value that can be specified,
to limit it to `typemax(Clong) ÷ 1000`. An `ArgumentError` is thrown if the
value is out of range.

This matches what libcurl expects [here](https://github.com/curl/curl/blob/4a8f6869db3a4ba7cd1bcb153c3d5b4298728afa/lib/setopt.c#L1376).

Originally reported at JuliaLang/Downloads.jl#193 and #23.
@codecov-commenter
Copy link

codecov-commenter commented Jul 20, 2022

Codecov Report

Merging #31 (12cb686) into main (904493e) will increase coverage by 0.54%.
The diff coverage is 100.00%.

@@            Coverage Diff             @@
##             main      #31      +/-   ##
==========================================
+ Coverage   91.33%   91.87%   +0.54%     
==========================================
  Files           5        5              
  Lines         323      320       -3     
==========================================
- Hits          295      294       -1     
+ Misses         28       26       -2     
Impacted Files Coverage Δ
src/curl.jl 90.39% <100.00%> (+0.95%) ⬆️
src/grpc.jl 90.62% <100.00%> (ø)

@tanmaykm tanmaykm merged commit eeb28a3 into main Jul 20, 2022
@delete-merged-branch delete-merged-branch bot deleted the tan/misc branch July 20, 2022 10:30
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.

2 participants