tests: stop using libcurl's strdup

It is not provided as a curlx function so should not be used outside of
libcurl.

I strongly suspect that no system we build the test suite on lack strdup
so this will not cause any harm.

The private version was added in b0936b8007 for Ultrix.

Closes #17297
This commit is contained in:
Daniel Stenberg 2025-05-08 23:29:24 +02:00
parent a129859367
commit 9468503330
No known key found for this signature in database
GPG key ID: 5CC908FDB71E12C2
2 changed files with 1 additions and 5 deletions

View file

@ -38,7 +38,6 @@ CURLX_SRCS = \
../../lib/curlx/timeval.c \
../../lib/curlx/dynbuf.c \
../../lib/strcase.c \
../../lib/strdup.c \
../../lib/curlx/multibyte.c \
../../lib/curlx/version_win32.c
@ -52,7 +51,6 @@ CURLX_HDRS = \
../../lib/curlx/timeval.h \
../../lib/curlx/dynbuf.h \
../../lib/strcase.h \
../../lib/strdup.h \
../../lib/curlx/multibyte.h \
../../lib/curlx/version_win32.h

View file

@ -51,8 +51,6 @@
#if defined(UNDER_CE)
#define system_strdup _strdup
#elif !defined(HAVE_STRDUP)
#define system_strdup Curl_strdup
#else
#define system_strdup strdup
#endif
@ -68,7 +66,7 @@ curl_realloc_callback Curl_crealloc = (curl_realloc_callback)realloc;
curl_strdup_callback Curl_cstrdup = (curl_strdup_callback)system_strdup;
curl_calloc_callback Curl_ccalloc = (curl_calloc_callback)calloc;
#if defined(_WIN32) && defined(UNICODE)
curl_wcsdup_callback Curl_cwcsdup = Curl_wcsdup;
curl_wcsdup_callback Curl_cwcsdup = NULL; /* not use in test code */
#endif
#if defined(_MSC_VER) && defined(_DLL)