mirror of
https://github.com/curl/curl.git
synced 2026-08-24 23:33:33 +03:00
version: rename threadsafe-init to threadsafe
Referring to Daniel's article [1], making the init function thread-safe was the last bit to make libcurl thread-safe as a whole. So the name of the feature may as well be the more concise 'threadsafe', also telling the story that libcurl is now fully thread-safe, not just its init function. Chances are high that libcurl wants to remain so in the future, so there is little likelihood of ever needing any other distinct `threadsafe-<name>` feature flags. For consistency we also shorten `CURL_VERSION_THREADSAFE_INIT` to `CURL_VERSION_THREADSAFE`, update its description and reference libcurl's thread safety documentation. [1]: https://daniel.haxx.se/blog/2022/06/08/making-libcurl-init-more-thread-safe/ Reviewed-by: Daniel Stenberg Reviewed-by: Jay Satiro Closes #8989
This commit is contained in:
parent
7ade9c50b3
commit
a94d6fe706
10 changed files with 16 additions and 16 deletions
|
|
@ -2611,7 +2611,7 @@ CURL_EXTERN void curl_free(void *p);
|
|||
* curl_global_init() should be invoked exactly once for each application that
|
||||
* uses libcurl and before any call of other libcurl functions.
|
||||
|
||||
* This function is thread-safe if CURL_VERSION_THREADSAFE_INIT is set in the
|
||||
* This function is thread-safe if CURL_VERSION_THREADSAFE is set in the
|
||||
* curl_version_info_data.features flag (fetch by curl_version_info()).
|
||||
|
||||
*/
|
||||
|
|
@ -3030,8 +3030,7 @@ typedef struct curl_version_info_data curl_version_info_data;
|
|||
#define CURL_VERSION_UNICODE (1<<27) /* Unicode support on Windows */
|
||||
#define CURL_VERSION_HSTS (1<<28) /* HSTS is supported */
|
||||
#define CURL_VERSION_GSASL (1<<29) /* libgsasl is supported */
|
||||
#define CURL_VERSION_THREADSAFE_INIT (1<<30) /* curl_global_init/cleanup() are
|
||||
thread-safe */
|
||||
#define CURL_VERSION_THREADSAFE (1<<30) /* libcurl API is thread-safe */
|
||||
|
||||
/*
|
||||
* NAME curl_version_info()
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue