aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/tool_getparam.c9
-rw-r--r--src/tool_getparam.h6
2 files changed, 12 insertions, 3 deletions
diff --git a/src/tool_getparam.c b/src/tool_getparam.c
index 429f12bda..fb8270894 100644
--- a/src/tool_getparam.c
+++ b/src/tool_getparam.c
@@ -290,9 +290,12 @@ static const struct feat feats[] = {
* We allow ':' and '\' to be escaped by '\' so that we can use certificate
* nicknames containing ':'. See <https://sourceforge.net/p/curl/bugs/1196/>
* for details. */
-static void parse_cert_parameter(const char *cert_parameter,
- char **certname,
- char **passphrase)
+#ifndef UNITTESTS
+static
+#endif
+void parse_cert_parameter(const char *cert_parameter,
+ char **certname,
+ char **passphrase)
{
size_t param_length = strlen(cert_parameter);
size_t span;
diff --git a/src/tool_getparam.h b/src/tool_getparam.h
index 38f0674f4..a86bfcec6 100644
--- a/src/tool_getparam.h
+++ b/src/tool_getparam.h
@@ -45,5 +45,11 @@ ParameterError getparameter(char *flag,
bool *usedarg,
struct Configurable *config);
+#ifdef UNITTESTS
+void parse_cert_parameter(const char *cert_parameter,
+ char **certname,
+ char **passphrase);
+#endif
+
#endif /* HEADER_CURL_TOOL_GETPARAM_H */