Skip to content

Commit

Permalink
ext/curl: Add all missing CURLE constants up to Curl 8.6
Browse files Browse the repository at this point in the history
ext/curl now requires libcurl 7.61.0, which means a lot of CURL* constants can be re-organized.

This commit re-arranges all of the CURLE_* constants to a single part of the `curl.stub.php` file,
and rearranges them to match the order of the error constants in the libcurl documentation[^1].

Constants that are deprecated[^2] are moved shifted to the end of the `CURLE_*` constants list.

[^1]: https://curl.se/libcurl/c/libcurl-errors.html
[^2]: https://curl.se/libcurl/c/symbols-in-versions.html

Related: php#12000, php#13259, php#13209, php#13282
  • Loading branch information
Ayesh committed May 6, 2024
1 parent 2d66993 commit ced94e0
Show file tree
Hide file tree
Showing 5 changed files with 1,933 additions and 1,409 deletions.
2 changes: 2 additions & 0 deletions NEWS
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,8 @@ PHP NEWS
. Deprecated the CURLOPT_BINARYTRANSFER constant. (divinity76)
. Bumped required libcurl version to 7.61.0. (Ayesh)
. Added feature_list key to the curl_version() return value (Ayesh)
. Added several CURLE_* constants, matching all error codes until libcurl
8.6.0 (Ayesh)

- Date:
. Added DateTime[Immutable]::createFromTimestamp. (Marc Bennewitz)
Expand Down
44 changes: 44 additions & 0 deletions UPGRADING
Original file line number Diff line number Diff line change
Expand Up @@ -555,6 +555,7 @@ PHP 8.4 UPGRADE NOTES

- Curl:
. The Curl extension now requires at least libcurl 7.61.0.
. Several CURLE_* constants added, supporting error codes upto libcurl 8.6.0.

- Intl:
. The class constants are typed now.
Expand Down Expand Up @@ -587,6 +588,49 @@ PHP 8.4 UPGRADE NOTES

- Core:
. PHP_OUTPUT_HANDLER_PROCESSED.
- Curl:
. CURLE_INTERFACE_FAILED
. CURLE_SSL_ENGINE_INITFAILED
. CURLE_SEND_FAIL_REWIND
. CURLE_LOGIN_DENIED
. CURLE_TFTP_UNKNOWNID
. CURLE_TFTP_PERM
. CURLE_TFTP_NOTFOUND
. CURLE_TFTP_NOSUCHUSER
. CURLE_TFTP_ILLEGAL
. CURLE_SSL_SHUTDOWN_FAILED
. CURLE_REMOTE_FILE_NOT_FOUND
. CURLE_UPLOAD_FAILED
. CURLE_USE_SSL_FAILED
. CURLE_REMOTE_FILE_EXISTS
. CURLE_REMOTE_DISK_FULL
. CURLE_REMOTE_ACCESS_DENIED
. CURLE_RANGE_ERROR
. CURLE_QUOTE_ERROR
. CURLE_FTP_COULDNT_SET_TYPE
. CURLE_PEER_FAILED_VERIFICATION
. CURLE_SSL_ISSUER_ERROR
. CURLE_SSL_CRL_BADFILE
. CURLE_RTSP_SESSION_ERROR
. CURLE_RTSP_CSEQ_ERROR
. CURLE_FTP_PRET_FAILED
. CURLE_FTP_BAD_FILE_LIST
. CURLE_CHUNK_FAILED
. CURLE_UNKNOWN_OPTION
. CURLE_NOT_BUILT_IN
. CURLE_FTP_ACCEPT_TIMEOUT
. CURLE_FTP_ACCEPT_FAILED
. CURLE_HTTP2
. CURLE_SSL_INVALIDCERTSTATUS
. CURLE_HTTP2_STREAM
. CURLE_RECURSIVE_API_CALL
. CURLE_AUTH_ERROR
. CURLE_HTTP3
. CURLE_QUIC_CONNECT_ERROR
. CURLE_SSL_CLIENTCERT
. CURLE_SETOPT_OPTION_SYNTAX
. CURLE_UNRECOVERABLE_POLL
. CURLE_TOO_LARGE

- Intl:
. The IntlDateFormatter class exposes now the new PATTERN constant
Expand Down

0 comments on commit ced94e0

Please sign in to comment.