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

pause: bail out on bad input #5050

Closed
wants to merge 1 commit into from
Closed

pause: bail out on bad input #5050

wants to merge 1 commit into from

Conversation

@bagder
Copy link
Member

bagder commented Mar 6, 2020

A NULL easy handle or an easy handle without an associated connection
cannot be paused or unpaused.

A NULL easy handle or an easy handle without an associated connection
cannot be paused or unpaused.
@bagder bagder force-pushed the bagder/pause-validate-input branch from 93d0d3b to 8272993 Mar 6, 2020
@bagder bagder closed this in e54b188 Mar 6, 2020
@bagder bagder deleted the bagder/pause-validate-input branch Mar 6, 2020
daviesrob added a commit to daviesrob/htslib that referenced this pull request Jul 14, 2020
Curl update curl/curl#5050 (pause: bail out
on bad input) made curl_easy_pause() return an error if passed
a disconnected CURL handle.  In hfile_libcurl this could happen
when libcurl_read() or libcurl_close() was called after all
bytes had been read; or all the time in restart_from_position().

Fix by checking for fp->finished in libcurl_read() and
libcurl_close(); and by removing the curl_easy_pause() in
restart_from_position().

Thanks to @jmarshall for tracking down the exact libcurl change
that caused the incompatibility.
whitwham pushed a commit to samtools/htslib that referenced this pull request Jul 15, 2020
Curl update curl/curl#5050 (pause: bail out
on bad input) made curl_easy_pause() return an error if passed
a disconnected CURL handle.  In hfile_libcurl this could happen
when libcurl_read() or libcurl_close() was called after all
bytes had been read; or all the time in restart_from_position().

Fix by checking for fp->finished in libcurl_read() and
libcurl_close(); and by removing the curl_easy_pause() in
restart_from_position().

Thanks to @jmarshall for tracking down the exact libcurl change
that caused the incompatibility.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked issues

Successfully merging this pull request may close these issues.

None yet

1 participant
You can’t perform that action at this time.