gnunet-svn
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[GNUnet-SVN] [gnurl] 132/219: ssh: define USE_SSH if SSH is enabled (any


From: gnunet
Subject: [GNUnet-SVN] [gnurl] 132/219: ssh: define USE_SSH if SSH is enabled (any backend)
Date: Wed, 22 May 2019 19:17:51 +0200

This is an automated email from the git hooks/post-receive script.

ng0 pushed a commit to branch master
in repository gnurl.

commit d37b0936d1ab9319d7b684eb7d9fc447174429bc
Author: Daniel Stenberg <address@hidden>
AuthorDate: Sun May 5 23:42:29 2019 +0200

    ssh: define USE_SSH if SSH is enabled (any backend)
    
    Closes #3846
---
 lib/curl_path.c  | 2 +-
 lib/curl_setup.h | 4 ++++
 lib/setopt.c     | 4 ++--
 lib/url.c        | 4 ++--
 lib/urldata.h    | 2 +-
 lib/version.c    | 4 ++--
 6 files changed, 12 insertions(+), 8 deletions(-)

diff --git a/lib/curl_path.c b/lib/curl_path.c
index ad386e743..85dddcef1 100644
--- a/lib/curl_path.c
+++ b/lib/curl_path.c
@@ -22,7 +22,7 @@
 
 #include "curl_setup.h"
 
-#if defined(USE_LIBSSH2) || defined(USE_LIBSSH)
+#if defined(USE_SSH)
 
 #include <curl/curl.h>
 #include "curl_memory.h"
diff --git a/lib/curl_setup.h b/lib/curl_setup.h
index 4c3a17359..e5b5c863b 100644
--- a/lib/curl_setup.h
+++ b/lib/curl_setup.h
@@ -686,6 +686,10 @@ int netware_init(void);
 #error "No longer supported. Set CURLOPT_CAINFO at runtime instead."
 #endif
 
+#if defined(USE_LIBSSH2) || defined(USE_LIBSSH) || defined(USE_WOLFSSH)
+#define USE_SSH
+#endif
+
 /*
  * Provide a mechanism to silence picky compilers, such as gcc 4.6+.
  * Parameters should of course normally not be unused, but for example when
diff --git a/lib/setopt.c b/lib/setopt.c
index da9ed3bb1..6352f486a 100644
--- a/lib/setopt.c
+++ b/lib/setopt.c
@@ -2217,7 +2217,7 @@ static CURLcode vsetopt(struct Curl_easy *data, 
CURLoption option,
     data->set.proxy_ssl.primary.sessionid = data->set.ssl.primary.sessionid;
     break;
 
-#if defined(USE_LIBSSH2) || defined(USE_LIBSSH)
+#ifdef USE_SSH
     /* we only include SSH options if explicitly built to support SSH */
   case CURLOPT_SSH_AUTH_TYPES:
     data->set.ssh_auth_types = va_arg(param, long);
@@ -2267,7 +2267,7 @@ static CURLcode vsetopt(struct Curl_easy *data, 
CURLoption option,
      */
     data->set.ssh_keyfunc_userp = va_arg(param, void *);
     break;
-#endif /* USE_LIBSSH2 */
+#endif /* USE_SSH */
 
   case CURLOPT_HTTP_TRANSFER_DECODING:
     /*
diff --git a/lib/url.c b/lib/url.c
index 5b3ce11f2..cd775af4a 100644
--- a/lib/url.c
+++ b/lib/url.c
@@ -186,11 +186,11 @@ static const struct Curl_handler * const protocols[] = {
   &Curl_handler_tftp,
 #endif
 
-#if defined(USE_LIBSSH2) || defined(USE_LIBSSH)
+#if defined(USE_SSH)
   &Curl_handler_scp,
 #endif
 
-#if defined(USE_LIBSSH2) || defined(USE_LIBSSH)
+#if defined(USE_SSH)
   &Curl_handler_sftp,
 #endif
 
diff --git a/lib/urldata.h b/lib/urldata.h
index 344cc472e..608b675df 100644
--- a/lib/urldata.h
+++ b/lib/urldata.h
@@ -1454,7 +1454,7 @@ enum dupstring {
   STRING_RTSP_SESSION_ID, /* Session ID to use */
   STRING_RTSP_STREAM_URI, /* Stream URI for this request */
   STRING_RTSP_TRANSPORT,  /* Transport for this session */
-#if defined(USE_LIBSSH2) || defined(USE_LIBSSH)
+#ifdef USE_SSH
   STRING_SSH_PRIVATE_KEY, /* path to the private key file for auth */
   STRING_SSH_PUBLIC_KEY,  /* path to the public key file for auth */
   STRING_SSH_HOST_PUBLIC_KEY_MD5, /* md5 of host public key in ascii hex */
diff --git a/lib/version.c b/lib/version.c
index 4c885dc33..87ebe0bc7 100644
--- a/lib/version.c
+++ b/lib/version.c
@@ -274,7 +274,7 @@ static const char * const protocols[] = {
 #ifndef CURL_DISABLE_RTSP
   "rtsp",
 #endif
-#if defined(USE_LIBSSH) || defined(USE_LIBSSH2)
+#if defined(USE_SSH)
   "scp",
   "sftp",
 #endif
@@ -390,7 +390,7 @@ static curl_version_info_data version_info = {
 curl_version_info_data *curl_version_info(CURLversion stamp)
 {
   static bool initialized;
-#if defined(USE_LIBSSH) || defined(USE_LIBSSH2)
+#if defined(USE_SSH)
   static char ssh_buffer[80];
 #endif
 #ifdef USE_SSL

-- 
To stop receiving notification emails like this one, please contact
address@hidden



reply via email to

[Prev in Thread] Current Thread [Next in Thread]