summaryrefslogtreecommitdiff
path: root/lib/asyn-thread.c
diff options
context:
space:
mode:
authorDaniel Stenberg <daniel@haxx.se>2021-04-19 10:46:11 +0200
committerDaniel Stenberg <daniel@haxx.se>2021-04-22 09:10:17 +0200
commit063d3f3b96e40b3bf770d04d90612064b9a53c49 (patch)
treedf0a46b661da2352d190a24e4c829ac6052c2a14 /lib/asyn-thread.c
parent19ea52da4df3c3ebc399ae25e705c7a8b5d45d95 (diff)
downloadcurl-063d3f3b96e40b3bf770d04d90612064b9a53c49.tar.gz
tidy-up: make conditional checks more consistent
... remove '== NULL' and '!= 0' Closes #6912
Diffstat (limited to 'lib/asyn-thread.c')
-rw-r--r--lib/asyn-thread.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/asyn-thread.c b/lib/asyn-thread.c
index c453203f7..cd93492f2 100644
--- a/lib/asyn-thread.c
+++ b/lib/asyn-thread.c
@@ -238,7 +238,7 @@ int init_thread_sync_data(struct thread_data *td,
#endif
tsd->mtx = malloc(sizeof(curl_mutex_t));
- if(tsd->mtx == NULL)
+ if(!tsd->mtx)
goto err_exit;
Curl_mutex_init(tsd->mtx);
@@ -305,7 +305,7 @@ static unsigned int CURL_STDCALL getaddrinfo_thread(void *arg)
rc = Curl_getaddrinfo_ex(tsd->hostname, service, &tsd->hints, &tsd->res);
- if(rc != 0) {
+ if(rc) {
tsd->sock_error = SOCKERRNO?SOCKERRNO:rc;
if(tsd->sock_error == 0)
tsd->sock_error = RESOLVER_ENOMEM;