mirror of
https://github.com/curl/curl.git
synced 2026-07-28 09:33:09 +03:00
asyn-thrdd: fix clang-tidy unused value warning
with `-DCURL_DISABLE_SOCKETPAIR=ON`.
```
lib/asyn-thrdd.c:227:5: error: Value stored to 'do_abort' is never read [clang-analyzer-deadcode.DeadStores,-warnings-as-errors]
227 | do_abort = addr_ctx->do_abort;
| ^ ~~~~~~~~~~~~~~~~~~
```
Closes #21061
This commit is contained in:
parent
757fd6aae9
commit
e8c64a06c5
1 changed files with 2 additions and 1 deletions
|
|
@ -223,10 +223,11 @@ static CURL_THREAD_RETURN_T CURL_STDCALL getaddrinfo_thread(void *arg)
|
|||
Curl_addrinfo_set_port(addr_ctx->res, addr_ctx->port);
|
||||
}
|
||||
|
||||
#ifndef CURL_DISABLE_SOCKETPAIR
|
||||
Curl_mutex_acquire(&addr_ctx->mutx);
|
||||
do_abort = addr_ctx->do_abort;
|
||||
Curl_mutex_release(&addr_ctx->mutx);
|
||||
#ifndef CURL_DISABLE_SOCKETPAIR
|
||||
|
||||
if(!do_abort) {
|
||||
/* Thread is done, notify transfer */
|
||||
int err = Curl_wakeup_signal(addr_ctx->sock_pair);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue