]> git.feebdaed.xyz Git - 0xmirror/curl.git/commitdiff
badwords: catch and fix threading-related words
authorViktor Szakats <commit@vsz.me>
Tue, 16 Dec 2025 19:01:16 +0000 (20:01 +0100)
committerViktor Szakats <commit@vsz.me>
Tue, 16 Dec 2025 20:26:58 +0000 (21:26 +0100)
Also:
- sync newlines between the two threaded examples.

Closes #20001

26 files changed:
.github/scripts/badwords.txt
RELEASE-NOTES
docs/examples/.gitignore
docs/examples/Makefile.inc
docs/examples/http2-upload.c
docs/examples/multithread.c [deleted file]
docs/examples/smooth-gtk-thread.c
docs/examples/threaded-ssl.c
docs/examples/threaded.c [new file with mode: 0644]
docs/libcurl/curl_global_cleanup.md
docs/libcurl/curl_global_init.md
docs/libcurl/curl_global_trace.md
docs/libcurl/libcurl-thread.md
docs/libcurl/libcurl-tutorial.md
docs/libcurl/libcurl.md
docs/libcurl/opts/CURLOPT_DNS_USE_GLOBAL_CACHE.md
include/curl/easy.h
lib/amigaos.c
lib/config-os400.h
lib/hostip.h
lib/hostip4.c
lib/http_ntlm.c
lib/memdebug.c
lib/vtls/gtls.c
m4/curl-functions.m4
tests/server/util.c

index 9e43c03fa8272d92ce596f5211c5c4fb624c1528..c5f91795dc0776a3a628e4f3ad2d336c01fcfa49 100644 (file)
@@ -10,6 +10,9 @@ tool chain:toolchain
 tool-chain:toolchain
 wild-card:wildcard
 wild card:wildcard
+\bthread ?safe[^."t]:thread-safe
+\bthread ?unsafe[^."t]:thread-unsafe
+multi ?thread:multi-thread
 \bit's:it is
 aren't:are not
 can't:cannot
index 8c70d4e7f14421bf0053cc41b605f15c56942432..d8e311f7f0580602f05478b6ea0a61dc8525229d 100644 (file)
@@ -107,7 +107,7 @@ This release includes the following bugfixes:
  o example: fix formatting nits [232]
  o examples/crawler: fix variable [92]
  o examples/multi-uv: fix invalid req->data access [177]
- o examples/multithread: fix race condition [101]
+ o examples/threaded: fix race condition [101]
  o examples: fix minor typo [203]
  o examples: make functions/data static where missing [139]
  o examples: tidy-up headers and includes [138]
index 788eefe1ef17f69ffb5a7755c93553bcb1bc023e..ffda1ce70a45102de4fda25ed29c0f815e85de43 100644 (file)
@@ -79,7 +79,6 @@ multi-legacy
 multi-post
 multi-single
 multi-uv
-multithread
 netrc
 parseurl
 persistent
@@ -123,6 +122,7 @@ smtp-tls
 smtp-vrfy
 sslbackend
 synctime
+threaded
 threaded-ssl
 unixsocket
 url2file
index 29c4e3e997bd1d4b6e1abe711d61458a3aa152b5..39b2efcd59af046dbdbd43ebb64676994a475c7e 100644 (file)
@@ -146,8 +146,8 @@ check_PROGRAMS = \
 COMPLICATED_MAY_BUILD = \
   cacertinmem.c \
   multi-uv.c \
-  multithread.c \
   sessioninfo.c \
+  threaded.c \
   threaded-ssl.c \
   usercertinmem.c
 
index 7becf5116926d35bcad86fc2048a8d6afa1ed04a..162c4c0d3610f75fa6520bb4cf3fd466ff5644b7 100644 (file)
@@ -161,7 +161,7 @@ static int my_trace(CURL *curl, curl_infotype type,
     known_offset = 1;
   }
   secs = epoch_offset + tv.tv_sec;
-  now = localtime(&secs);  /* not thread safe but we do not care */
+  now = localtime(&secs);  /* not thread-safe but we do not care */
   snprintf(timebuf, sizeof(timebuf), "%02d:%02d:%02d.%06ld",
            now->tm_hour, now->tm_min, now->tm_sec, (long)tv.tv_usec);
 
diff --git a/docs/examples/multithread.c b/docs/examples/multithread.c
deleted file mode 100644 (file)
index 3d2f1df..0000000
+++ /dev/null
@@ -1,112 +0,0 @@
-/***************************************************************************
- *                                  _   _ ____  _
- *  Project                     ___| | | |  _ \| |
- *                             / __| | | | |_) | |
- *                            | (__| |_| |  _ <| |___
- *                             \___|\___/|_| \_\_____|
- *
- * Copyright (C) Daniel Stenberg, <daniel@haxx.se>, et al.
- *
- * This software is licensed as described in the file COPYING, which
- * you should have received as part of this distribution. The terms
- * are also available at https://curl.se/docs/copyright.html.
- *
- * You may opt to use, copy, modify, merge, publish, distribute and/or sell
- * copies of the Software, and permit persons to whom the Software is
- * furnished to do so, under the terms of the COPYING file.
- *
- * This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY
- * KIND, either express or implied.
- *
- * SPDX-License-Identifier: curl
- *
- ***************************************************************************/
-/* <DESC>
- * A multi-threaded program using pthreads to fetch several files at once
- * </DESC>
- */
-
-/* Requires: HAVE_PTHREAD_H */
-
-#include <stdio.h>
-
-#include <pthread.h>
-
-#include <curl/curl.h>
-
-#define NUMT 4
-
-/*
-  List of URLs to fetch.
-
-  If you intend to use an SSL-based protocol here you might need to setup TLS
-  library mutex callbacks as described here:
-
-  https://curl.se/libcurl/c/threadsafe.html
-
-*/
-static const char * const urls[NUMT] = {
-  "https://curl.se/",
-  "ftp://example.com/",
-  "https://example.net/",
-  "www.example"
-};
-
-struct targ {
-  const char *url;
-};
-
-static void *pull_one_url(void *p)
-{
-  CURL *curl;
-  struct targ *targ = p;
-
-  curl = curl_easy_init();
-  if(curl) {
-    curl_easy_setopt(curl, CURLOPT_URL, targ->url);
-    (void)curl_easy_perform(curl); /* ignores error */
-    curl_easy_cleanup(curl);
-  }
-
-  return NULL;
-}
-
-/*
-   int pthread_create(pthread_t *new_thread_ID,
-   const pthread_attr_t *attr,
-   void * (*start_func)(void *), void *arg);
-*/
-
-int main(void)
-{
-  CURLcode res;
-  pthread_t tid[NUMT];
-  struct targ targs[NUMT];
-  int i;
-
-  /* Must initialize libcurl before any threads are started */
-  res = curl_global_init(CURL_GLOBAL_ALL);
-  if(res)
-    return (int)res;
-
-  for(i = 0; i < NUMT; i++) {
-    int error;
-    targs[i].url = urls[i];
-    error = pthread_create(&tid[i],
-                           NULL, /* default attributes please */
-                           pull_one_url,
-                           (void *)&targs[i]);
-    if(error)
-      fprintf(stderr, "Could not run thread number %d, errno %d\n", i, error);
-    else
-      fprintf(stderr, "Thread %d, gets %s\n", i, urls[i]);
-  }
-
-  /* now wait for all threads to terminate */
-  for(i = 0; i < NUMT; i++) {
-    pthread_join(tid[i], NULL);
-    fprintf(stderr, "Thread %d terminated\n", i);
-  }
-  curl_global_cleanup();
-  return 0;
-}
index 6bf8946721aa2e7b6d254947754190ad01c5297c..bf165f7e42156789eb173d43f323c8ac8e39afab 100644 (file)
@@ -22,8 +22,8 @@
  *
  ***************************************************************************/
 /* <DESC>
- * A multi threaded application that uses a progress bar to show
- * status.  It uses Gtk+ to make a smooth pulse.
+ * A multi-threaded application that uses a progress bar to show
+ * status. It uses Gtk+ to make a smooth pulse.
  * </DESC>
  */
 /*
index 8d5d1234fcb2bbd446a7466ad4c84a22118c1ce1..d8053d3cccecffb5261c13bfb04702e31de1dd2d 100644 (file)
@@ -29,7 +29,7 @@
 /* A multi-threaded example that uses pthreads and fetches 4 remote files at
  * once over HTTPS.
  *
- * Recent versions of OpenSSL and GnuTLS are thread safe by design, assuming
+ * Recent versions of OpenSSL and GnuTLS are thread-safe by design, assuming
  * support for the underlying OS threading API is built-in. Older revisions
  * of this example demonstrated locking callbacks for the SSL library, which
  * are no longer necessary. An older revision with callbacks can be found at
@@ -40,7 +40,9 @@
 /* Also requires TLS support to run */
 
 #include <stdio.h>
+
 #include <pthread.h>
+
 #include <curl/curl.h>
 
 #define NUMT 4
diff --git a/docs/examples/threaded.c b/docs/examples/threaded.c
new file mode 100644 (file)
index 0000000..4e56312
--- /dev/null
@@ -0,0 +1,114 @@
+/***************************************************************************
+ *                                  _   _ ____  _
+ *  Project                     ___| | | |  _ \| |
+ *                             / __| | | | |_) | |
+ *                            | (__| |_| |  _ <| |___
+ *                             \___|\___/|_| \_\_____|
+ *
+ * Copyright (C) Daniel Stenberg, <daniel@haxx.se>, et al.
+ *
+ * This software is licensed as described in the file COPYING, which
+ * you should have received as part of this distribution. The terms
+ * are also available at https://curl.se/docs/copyright.html.
+ *
+ * You may opt to use, copy, modify, merge, publish, distribute and/or sell
+ * copies of the Software, and permit persons to whom the Software is
+ * furnished to do so, under the terms of the COPYING file.
+ *
+ * This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY
+ * KIND, either express or implied.
+ *
+ * SPDX-License-Identifier: curl
+ *
+ ***************************************************************************/
+/* <DESC>
+ * A multi-threaded program using pthreads to fetch several files at once
+ * </DESC>
+ */
+
+/* Requires: HAVE_PTHREAD_H */
+
+#include <stdio.h>
+
+#include <pthread.h>
+
+#include <curl/curl.h>
+
+#define NUMT 4
+
+/*
+  List of URLs to fetch.
+
+  If you intend to use an SSL-based protocol here you might need to setup TLS
+  library mutex callbacks as described here:
+
+  https://curl.se/libcurl/c/threadsafe.html
+
+*/
+static const char * const urls[NUMT] = {
+  "https://curl.se/",
+  "ftp://example.com/",
+  "https://example.net/",
+  "www.example"
+};
+
+struct targ {
+  const char *url;
+};
+
+static void *pull_one_url(void *p)
+{
+  CURL *curl;
+  struct targ *targ = p;
+
+  curl = curl_easy_init();
+  if(curl) {
+    curl_easy_setopt(curl, CURLOPT_URL, targ->url);
+    (void)curl_easy_perform(curl); /* ignores error */
+    curl_easy_cleanup(curl);
+  }
+
+  return NULL;
+}
+
+/*
+   int pthread_create(pthread_t *new_thread_ID,
+   const pthread_attr_t *attr,
+   void * (*start_func)(void *), void *arg);
+*/
+
+int main(void)
+{
+  CURLcode res;
+  pthread_t tid[NUMT];
+  struct targ targs[NUMT];
+  int i;
+
+  /* Must initialize libcurl before any threads are started */
+  res = curl_global_init(CURL_GLOBAL_ALL);
+  if(res)
+    return (int)res;
+
+  for(i = 0; i < NUMT; i++) {
+    int error;
+    targs[i].url = urls[i];
+    error = pthread_create(&tid[i],
+                           NULL, /* default attributes please */
+                           pull_one_url,
+                           (void *)&targs[i]);
+    if(error)
+      fprintf(stderr, "Could not run thread number %d, errno %d\n", i, error);
+    else
+      fprintf(stderr, "Thread %d, gets %s\n", i, urls[i]);
+  }
+
+  /* now wait for all threads to terminate */
+  for(i = 0; i < NUMT; i++) {
+    pthread_join(tid[i], NULL);
+    fprintf(stderr, "Thread %d terminated\n", i);
+  }
+
+  curl_global_cleanup();
+
+  return 0;
+}
index 60a761ed5c505b2a78a6f0a80778a006389fab0a..1c3dac9aa35f9a19afb9297af2db32f895b03f00 100644 (file)
@@ -40,7 +40,7 @@ If this is not thread-safe, you must not call this function when any other
 thread in the program (i.e. a thread sharing the same memory) is running.
 This does not just mean no other thread that is using libcurl. Because
 curl_global_cleanup(3) calls functions of other libraries that are
-similarly thread unsafe, it could conflict with any other thread that uses
+similarly thread-unsafe, it could conflict with any other thread that uses
 these other libraries.
 
 See the description in libcurl(3) of global environment requirements for
index 724f90cddc8f3991920cfdc487262cd00c5d3be0..093a530351ecd38a3c15382361037449255c5767 100644 (file)
@@ -52,7 +52,7 @@ If this is not thread-safe (the bit mentioned above is not set), you must not
 call this function when any other thread in the program (i.e. a thread sharing
 the same memory) is running. This does not just mean no other thread that is
 using libcurl. Because curl_global_init(3) calls functions of other libraries
-that are similarly thread unsafe, it could conflict with any other thread that
+that are similarly thread-unsafe, it could conflict with any other thread that
 uses these other libraries.
 
 If you are initializing libcurl from a Windows DLL you should not initialize
index 10ec21b4bd43d6b27e163c816f9b3a5e37204215..fa08df7c72ef6ed0cdeab6facf51521221d64862 100644 (file)
@@ -43,7 +43,7 @@ If this is not thread-safe, you must not call this function when any other
 thread in the program (i.e. a thread sharing the same memory) is running. This
 does not just mean no other thread that is using libcurl. Because
 curl_global_init(3) may call functions of other libraries that are similarly
-thread unsafe, it could conflict with any other thread that uses these other
+thread-unsafe, it could conflict with any other thread that uses these other
 libraries.
 
 If you are initializing libcurl from a Windows DLL you should not initialize
index ef7ae9b7d901f01d675bb475691088604f109210..a56f6b19c8bf775ab27e9b5bedcb3e421ec5d7ec 100644 (file)
@@ -17,7 +17,7 @@ libcurl-thread - libcurl thread safety
 
 # Multi-threading with libcurl
 
-libcurl is thread safe but has no internal thread synchronization. You may have
+libcurl is thread-safe but has no internal thread synchronization. You may have
 to provide your own locking should you meet any of the thread safety exceptions
 below.
 
@@ -84,10 +84,10 @@ the former signal handler while another thread should still ignore it.
 # Name resolving
 
 The **gethostbyname** or **getaddrinfo** and other name resolving system
-calls used by libcurl are provided by your operating system and must be thread
-safe. It is important that libcurl can find and use thread safe versions of
-these and other system calls, as otherwise it cannot function fully thread
-safe. Some operating systems are known to have faulty thread
+calls used by libcurl are provided by your operating system and must be
+thread-safe. It is important that libcurl can find and use thread-safe versions
+of these and other system calls, as otherwise it cannot function fully
+thread-safe. Some operating systems are known to have faulty thread
 implementations. We have previously received problem reports on *BSD (at least
 in the past, they may be working fine these days). Some operating systems that
 are known to have solid and working thread support are Linux, Solaris and
@@ -110,7 +110,7 @@ libcurl(3) section **GLOBAL CONSTANTS**.
 # Memory functions
 
 These functions, provided either by your operating system or your own
-replacements, must be thread safe. You can use curl_global_init_mem(3)
+replacements, must be thread-safe. You can use curl_global_init_mem(3)
 to set your own replacement memory functions.
 
 # Non-safe functions
index a5bebc6655980c651c9bfbd984fbededea00b080..6cfe354fc1af2f6554b7323e9ece6290b86a16dc 100644 (file)
@@ -272,7 +272,7 @@ all the details needed to get the file moved from one machine to another.
 
 # Multi-threading Issues
 
-libcurl is thread safe but there are a few exceptions. Refer to
+libcurl is thread-safe but there are a few exceptions. Refer to
 libcurl-thread(3) for more information.
 
 # When It does not Work
index b6d4af36e35d750d6978f416a52dcdf5a4190d08..47bf21008704eaa1df9c83c83b596e16d4853b23 100644 (file)
@@ -129,7 +129,7 @@ the same, on any of the platforms it compiles and builds on.
 
 # THREADS
 
-libcurl is thread safe but there are a few exceptions. Refer to
+libcurl is thread-safe but there are a few exceptions. Refer to
 libcurl-thread(3) for more information.
 
 # PERSISTENT CONNECTIONS
@@ -176,7 +176,7 @@ The global constant functions are thread-safe since libcurl 7.84.0 if
 curl_version_info(3) has the CURL_VERSION_THREADSAFE feature bit set
 (most platforms). Read libcurl-thread(3) for thread safety guidelines.
 
-If the global constant functions are *not thread safe*, then you must
+If the global constant functions are *not thread-safe*, then you must
 not call them when any other thread in the program is running. It
 is not good enough that no other thread is using libcurl at the time,
 because these functions internally call similar functions of other
@@ -184,7 +184,7 @@ libraries, and those functions are similarly thread-unsafe. You cannot
 generally know what these libraries are, or whether other threads are
 using them.
 
-If the global constant functions are *not thread safe*, then the basic rule
+If the global constant functions are *not thread-safe*, then the basic rule
 for constructing a program that uses libcurl is this: Call
 curl_global_init(3), with a *CURL_GLOBAL_ALL* argument, immediately
 after the program starts, while it is still only one thread and before it uses
index 67fba7914257798e8fc2e136b3e9c0fb23c15e9a..0bc37a6a4e1227981e3e28b31af85aa304f3dacd 100644 (file)
@@ -51,7 +51,7 @@ int main(void)
   if(curl) {
     CURLcode ret;
     curl_easy_setopt(curl, CURLOPT_URL, "https://example.com/");
-    /* switch off the use of a global, thread unsafe, cache */
+    /* switch off the use of a global, thread-unsafe, cache */
     curl_easy_setopt(curl, CURLOPT_DNS_USE_GLOBAL_CACHE, 0L);
     ret = curl_easy_perform(curl);
     curl_easy_cleanup(curl);
index 85cfd830f7e2c7dc9c6aa842bab3e5dc849760b8..5b3cdbd64e805870cf8a30193cb945ef99e446d8 100644 (file)
@@ -66,7 +66,7 @@ CURL_EXTERN CURLcode curl_easy_getinfo(CURL *curl, CURLINFO info, ...);
  * Creates a new curl session handle with the same options set for the handle
  * passed in. Duplicating a handle could only be a matter of cloning data and
  * options, internal state info and things like persistent connections cannot
- * be transferred. It is useful in multithreaded applications when you can run
+ * be transferred. It is useful in multi-threaded applications when you can run
  * curl_easy_duphandle() for each new thread to avoid a series of identical
  * curl_easy_setopt() invokes in every thread.
  */
index d32ee5e7902fdeb9bd3c5ff5599d16fff270518b..d4c1c2c856056c01ab8d9f9ce1159878d8a1a2b9 100644 (file)
@@ -116,7 +116,7 @@ void Curl_amiga_cleanup(void)
  * Because we need to handle the different cases in hostip4.c at runtime,
  * not at compile-time, based on what was detected in Curl_amiga_init(),
  * we replace it completely with our own as to not complicate the baseline
- * code. Assumes malloc/calloc/free are thread safe because Curl_he2ai()
+ * code. Assumes malloc/calloc/free are thread-safe because Curl_he2ai()
  * allocates memory also.
  */
 
@@ -144,7 +144,7 @@ struct Curl_addrinfo *Curl_ipv4_resolve_r(const char *hostname, int port)
   }
   else {
 #ifdef CURLRES_THREADED
-    /* gethostbyname() is not thread safe, so we need to reopen bsdsocket
+    /* gethostbyname() is not thread-safe, so we need to reopen bsdsocket
      * on the thread's context
      */
     struct Library *base = OpenLibrary("bsdsocket.library", 4);
index ab7f670d830087309eb65d30351a0a49cd2b274e..ec6c002efd785a7940515a65cbbe6c4c10fbee64 100644 (file)
@@ -38,9 +38,9 @@
 /* OS400 supports a 3-argument ASCII version of gethostbyaddr_r(), but its
  *  prototype is incompatible with the "standard" one (1st argument is not
  *  const). However, getaddrinfo() is supported (ASCII version defined as
- *  a local wrapper in setup-os400.h) in a threadsafe way: we can then
+ *  a local wrapper in setup-os400.h) in a thread-safe way: we can then
  *  configure getaddrinfo() as such and get rid of gethostbyname_r() without
- *  loss of threadsafeness. */
+ *  loss of thread-safeness. */
 #undef HAVE_GETHOSTBYNAME_R
 #undef HAVE_GETHOSTBYNAME_R_3
 #undef HAVE_GETHOSTBYNAME_R_5
index 3672a03506b378e8e1b49b765907978f22adc56f..8b3b962078296e012ed2a7f4714f8738ce8f1c7a 100644 (file)
@@ -131,7 +131,7 @@ void Curl_dnscache_prune(struct Curl_easy *data);
 /* clear the DNS cache */
 void Curl_dnscache_clear(struct Curl_easy *data);
 
-/* IPv4 threadsafe resolve function used for synch and asynch builds */
+/* IPv4 thread-safe resolve function used for synch and asynch builds */
 struct Curl_addrinfo *Curl_ipv4_resolve_r(const char *hostname, int port);
 
 CURLcode Curl_once_resolved(struct Curl_easy *data,
index ada021176983bedc4238823879b63ec17537e13f..9d5987c68a40f9d879cc15f4fe6c8b1d2ce65512 100644 (file)
@@ -93,10 +93,10 @@ struct Curl_addrinfo *Curl_sync_getaddrinfo(struct Curl_easy *data,
 #if defined(CURLRES_IPV4) && !defined(CURLRES_ARES) && !defined(CURLRES_AMIGA)
 
 /*
- * Curl_ipv4_resolve_r() - ipv4 threadsafe resolver function.
+ * Curl_ipv4_resolve_r() - ipv4 thread-safe resolver function.
  *
  * This is used for both synchronous and asynchronous resolver builds,
- * implying that only threadsafe code and function calls may be used.
+ * implying that only thread-safe code and function calls may be used.
  *
  */
 struct Curl_addrinfo *Curl_ipv4_resolve_r(const char *hostname,
@@ -153,7 +153,7 @@ struct Curl_addrinfo *Curl_ipv4_resolve_r(const char *hostname,
                       &h_errnop);
 
   /* If the buffer is too small, it returns NULL and sets errno to
-   * ERANGE. The errno is thread safe if this is compiled with
+   * ERANGE. The errno is thread-safe if this is compiled with
    * -D_REENTRANT as then the 'errno' variable is a macro defined to get
    * used properly for threads.
    */
@@ -263,7 +263,7 @@ struct Curl_addrinfo *Curl_ipv4_resolve_r(const char *hostname,
 #else /* (HAVE_GETADDRINFO && HAVE_GETADDRINFO_THREADSAFE) ||
           HAVE_GETHOSTBYNAME_R */
   /*
-   * Here is code for platforms that do not have a thread safe
+   * Here is code for platforms that do not have a thread-safe
    * getaddrinfo() nor gethostbyname_r() function or for which
    * gethostbyname() is the preferred one.
    */
index 8d15a8a16227498a9b97bd59e924e7449fdfe230..62a33021baabaeff9da7d2bbf24ade220359920d 100644 (file)
@@ -176,7 +176,7 @@ CURLcode Curl_output_ntlm(struct Curl_easy *data, bool proxy)
 
 #ifdef USE_WINDOWS_SSPI
   if(!Curl_pSecFn) {
-    /* not thread safe and leaks - use curl_global_init() to avoid */
+    /* not thread-safe and leaks - use curl_global_init() to avoid */
     CURLcode err = Curl_sspi_global_init();
     if(!Curl_pSecFn)
       return err;
index 05cd45a6f9bd724807e3ea19d374f956b916f62e..7587a1001c571efc05b13c34d20bfdd6e48a0cc2 100644 (file)
@@ -52,7 +52,7 @@ struct memdebug {
  * For advanced analysis, record a log file and write perl scripts to analyze
  * them!
  *
- * Do not use these with multithreaded test programs!
+ * Do not use these with multi-threaded test programs!
  */
 
 FILE *curl_dbg_logfile = NULL;
index b9e462342a4843216a1425d2ddf2f98ce7bfb6db..9e8836773796de49d48824e94edf8d6a10cf02f3 100644 (file)
@@ -149,7 +149,7 @@ static ssize_t gtls_pull(void *s, void *buf, size_t blen)
  * gtls_init()
  *
  * Global GnuTLS init, called from Curl_ssl_init(). This calls functions that
- * are not thread-safe (It is thread safe since GnuTLS 3.3.0) and thus this
+ * are not thread-safe (It is thread-safe since GnuTLS 3.3.0) and thus this
  * function itself is not thread-safe and must only be called from within
  * curl_global_init() to keep the thread situation under control!
  *
index 932b1de2d9a2a7b409aebbb3f3f6ae2ecb01a530..52885d84a84cb6d20266a615e4815d5ccb8eef6e 100644 (file)
@@ -1265,7 +1265,7 @@ dnl true, and usage has not been previously disallowed
 dnl with shell variable curl_disallow_getaddrinfo, then
 dnl HAVE_GETADDRINFO will be defined. Additionally when
 dnl HAVE_GETADDRINFO gets defined this will also attempt
-dnl to find out if getaddrinfo happens to be threadsafe,
+dnl to find out if getaddrinfo happens to be thread-safe,
 dnl defining HAVE_GETADDRINFO_THREADSAFE when true.
 
 AC_DEFUN([CURL_CHECK_FUNC_GETADDRINFO], [
@@ -1414,7 +1414,7 @@ AC_DEFUN([CURL_CHECK_FUNC_GETADDRINFO], [
   fi
   #
   if test "$curl_cv_func_getaddrinfo" = "yes"; then
-    AC_MSG_CHECKING([if getaddrinfo is threadsafe])
+    AC_MSG_CHECKING([if getaddrinfo is thread-safe])
     if test "$curl_cv_apple" = "yes"; then
       dnl Darwin 6.0 and macOS 10.2.X and newer
       tst_tsafe_getaddrinfo="yes"
@@ -1479,7 +1479,7 @@ AC_DEFUN([CURL_CHECK_FUNC_GETADDRINFO], [
     AC_MSG_RESULT([$tst_tsafe_getaddrinfo])
     if test "$tst_tsafe_getaddrinfo" = "yes"; then
       AC_DEFINE_UNQUOTED(HAVE_GETADDRINFO_THREADSAFE, 1,
-        [Define to 1 if the getaddrinfo function is threadsafe.])
+        [Define to 1 if the getaddrinfo function is thread-safe.])
       curl_cv_func_getaddrinfo_threadsafe="yes"
     else
       curl_cv_func_getaddrinfo_threadsafe="no"
index 043de037ae32673c320ce0c758270ec7b9466f2f..529ead7b86bea3cf2878039a93657a518fec34ae 100644 (file)
@@ -407,7 +407,7 @@ static void exit_signal_handler(int signum)
  * SIGINT is not supported for any Win32 application. When a CTRL+C
  * interrupt occurs, Win32 operating systems generate a new thread
  * to specifically handle that interrupt. This can cause a single-thread
- * application, such as one in UNIX, to become multithreaded and cause
+ * application, such as one in UNIX, to become multi-threaded and cause
  * unexpected behavior.
  * [...]
  * The SIGKILL and SIGTERM signals are not generated under Windows.