mirror of
https://github.com/curl/curl.git
synced 2026-07-27 08:47:21 +03:00
Gerrit Bruchhuser pointed out a warning that the Intel(R) Thread Checker
tool reports and it was indeed a legitimate one and it is one fixed. It was a use of a share without doing the proper locking first.
This commit is contained in:
parent
d978f85d55
commit
a1b650ad7b
4 changed files with 50 additions and 34 deletions
|
|
@ -378,8 +378,11 @@ CURLcode Curl_close(struct SessionHandle *data)
|
|||
#endif /* CURL_DOES_CONVERSIONS && HAVE_ICONV */
|
||||
|
||||
/* No longer a dirty share, if it exists */
|
||||
if (data->share)
|
||||
if (data->share) {
|
||||
Curl_share_lock(data, CURL_LOCK_DATA_SHARE, CURL_LOCK_ACCESS_SINGLE);
|
||||
data->share->dirty--;
|
||||
Curl_share_unlock(data, CURL_LOCK_DATA_SHARE);
|
||||
}
|
||||
|
||||
free(data);
|
||||
return CURLE_OK;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue