[Webkit-unassigned] [Bug 256071] New: [Curl] Use CURL_WRITEFUNC_ERROR when aborting CURLOPT_WRITEFUNCTION
bugzilla-daemon at webkit.org
bugzilla-daemon at webkit.org
Thu Apr 27 20:32:25 PDT 2023
https://bugs.webkit.org/show_bug.cgi?id=256071
Bug ID: 256071
Summary: [Curl] Use CURL_WRITEFUNC_ERROR when aborting
CURLOPT_WRITEFUNCTION
Product: WebKit
Version: WebKit Nightly Build
Hardware: Unspecified
OS: Unspecified
Status: NEW
Severity: Normal
Priority: P2
Component: Platform
Assignee: webkit-unassigned at lists.webkit.org
Reporter: kenji.shukuwa at open-tec.co.jp
We are returning 0 when aborting CURLOPT_HEADERFUNCTION or CURLOPT_WRITEFUNCTION, which seems to be misuse in some cases.
So use CURL_WRITEFUNC_ERROR which was added in 7.87.0 instead.
https://github.com/curl/curl/pull/9874
---
Also, the inclination of some users has been to just return 0 to signal error, which is incorrect as that may be the number of bytes passed to the callback.
---
https://curl.se/libcurl/c/CURLOPT_WRITEFUNCTION.html
https://curl.se/libcurl/c/CURLOPT_HEADERFUNCTION.html
---
You can also abort the transfer by returning CURL_WRITEFUNC_ERROR. (7.87.0)
---
--
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.webkit.org/pipermail/webkit-unassigned/attachments/20230428/19414953/attachment.htm>
More information about the webkit-unassigned
mailing list