]> git.ipfire.org Git - thirdparty/curl.git/commitdiff
CURLSHOPT_SHARE.md: mention multi-threading requires callbacks
authorJay Satiro <raysatiro@yahoo.com>
Mon, 30 Jun 2025 05:53:43 +0000 (01:53 -0400)
committerJay Satiro <raysatiro@yahoo.com>
Wed, 2 Jul 2025 15:11:25 +0000 (11:11 -0400)
- Explain that if data is shared in multiple threads then the user must
  set mutex callbacks.

Reported-by: afengsoft@users.noreply.github.com
Fixes https://github.com/curl/curl/issues/17774
Closes https://github.com/curl/curl/pull/17782

docs/libcurl/opts/CURLSHOPT_SHARE.md

index d4e3fc4dfbbed732b1cc68662172ec016ab846c2..4171430a790a4ede93a808a5a7782585a867dffe 100644 (file)
@@ -35,6 +35,9 @@ CURLSHOPT_SHARE(3) multiple times with different data arguments to have
 the share object share multiple types of data. Unset a type again by setting
 CURLSHOPT_UNSHARE(3).
 
+If any of the data is to be shared in multiple threads then mutex callbacks
+must be set as well. See CURLSHOPT_LOCKFUNC(3) and CURLSHOPT_UNLOCKFUNC(3).
+
 ## CURL_LOCK_DATA_COOKIE
 
 Cookie data is shared across the easy handles using this shared object. Note