ssh: add a generic Curl_ssh_version function for SSH backends

Closes #4235
This commit is contained in:
Daniel Stenberg 2019-08-16 15:32:05 +02:00
parent 1a7634e484
commit ea28a6cb2f
No known key found for this signature in database
GPG key ID: 5CC908FDB71E12C2
4 changed files with 27 additions and 30 deletions

View file

@ -2739,4 +2739,9 @@ void Curl_ssh_cleanup(void)
(void)ssh_finalize();
}
size_t Curl_ssh_version(char *buffer, size_t buflen)
{
return msnprintf(buffer, buflen, "libssh/%s", CURL_LIBSSH_VERSION);
}
#endif /* USE_LIBSSH */

View file

@ -3338,5 +3338,9 @@ void Curl_ssh_cleanup(void)
#endif
}
size_t Curl_ssh_version(char *buffer, size_t buflen)
{
return msnprintf(buffer, buflen, "libssh2/%s", LIBSSH2_VERSION);
}
#endif /* USE_LIBSSH2 */