gnunet-svn
[Top][All Lists]
Advanced

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

[GNUnet-SVN] [gnurl] 29/254: http-proxy: remove unused argument from Cur


From: gnunet
Subject: [GNUnet-SVN] [gnurl] 29/254: http-proxy: remove unused argument from Curl_proxyCONNECT()
Date: Sat, 17 Jun 2017 16:51:01 +0200

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

ng0 pushed a commit to annotated tag gnurl-7.54.1
in repository gnurl.

commit 55c3c02e59d1daf31ec2097f93b8139ddb3fdeb6
Author: Daniel Stenberg <address@hidden>
AuthorDate: Wed Apr 26 00:34:22 2017 +0200

    http-proxy: remove unused argument from Curl_proxyCONNECT()
---
 lib/ftp.c        |  2 +-
 lib/http_proxy.c | 20 ++++++--------------
 lib/http_proxy.h |  5 ++---
 3 files changed, 9 insertions(+), 18 deletions(-)

diff --git a/lib/ftp.c b/lib/ftp.c
index 059bd2ac0..a33a4e0ae 100644
--- a/lib/ftp.c
+++ b/lib/ftp.c
@@ -3587,7 +3587,7 @@ static CURLcode ftp_do_more(struct connectdata *conn, int 
*completep)
     if(conn->tunnel_state[SECONDARYSOCKET] == TUNNEL_CONNECT) {
       /* As we're in TUNNEL_CONNECT state now, we know the proxy name and port
          aren't used so we blank their arguments. TODO: make this nicer */
-      result = Curl_proxyCONNECT(conn, SECONDARYSOCKET, NULL, 0, FALSE);
+      result = Curl_proxyCONNECT(conn, SECONDARYSOCKET, NULL, 0);
 
       return result;
     }
diff --git a/lib/http_proxy.c b/lib/http_proxy.c
index d53685f53..3c6a835f6 100644
--- a/lib/http_proxy.c
+++ b/lib/http_proxy.c
@@ -122,8 +122,7 @@ CURLcode Curl_proxy_connect(struct connectdata *conn, int 
sockindex)
       remote_port = conn->conn_to_port;
     else
       remote_port = conn->remote_port;
-    result = Curl_proxyCONNECT(conn, sockindex, hostname,
-                               remote_port, FALSE);
+    result = Curl_proxyCONNECT(conn, sockindex, hostname, remote_port);
     conn->data->req.protop = prot_save;
     if(CURLE_OK != result)
       return result;
@@ -140,16 +139,12 @@ CURLcode Curl_proxy_connect(struct connectdata *conn, int 
sockindex)
  * Curl_proxyCONNECT() requires that we're connected to a HTTP proxy. This
  * function will issue the necessary commands to get a seamless tunnel through
  * this proxy. After that, the socket can be used just as a normal socket.
- *
- * 'blocking' set to TRUE means that this function will do the entire CONNECT
- * + response in a blocking fashion. Should be avoided!
  */
 
 CURLcode Curl_proxyCONNECT(struct connectdata *conn,
                            int sockindex,
                            const char *hostname,
-                           int remote_port,
-                           bool blocking)
+                           int remote_port)
 {
   int subversion=0;
   struct Curl_easy *data=conn->data;
@@ -289,13 +284,10 @@ CURLcode Curl_proxyCONNECT(struct connectdata *conn,
       return CURLE_RECV_ERROR;
     }
 
-    if(!blocking) {
-      if(!Curl_conn_data_pending(conn, sockindex))
-        /* return so we'll be called again polling-style */
-        return CURLE_OK;
-      DEBUGF(infof(data,
-             "Read response immediately from proxy CONNECT\n"));
-    }
+    if(!Curl_conn_data_pending(conn, sockindex))
+      /* return so we'll be called again polling-style */
+      return CURLE_OK;
+    DEBUGF(infof(data, "Read response immediately from proxy CONNECT\n"));
 
     /* at this point, the tunnel_connecting phase is over. */
 
diff --git a/lib/http_proxy.h b/lib/http_proxy.h
index d1f5a7c83..81b7b8b8b 100644
--- a/lib/http_proxy.h
+++ b/lib/http_proxy.h
@@ -7,7 +7,7 @@
  *                            | (__| |_| |  _ <| |___
  *                             \___|\___/|_| \_\_____|
  *
- * Copyright (C) 1998 - 2015, Daniel Stenberg, <address@hidden>, et al.
+ * Copyright (C) 1998 - 2017, Daniel Stenberg, <address@hidden>, et al.
  *
  * This software is licensed as described in the file COPYING, which
  * you should have received as part of this distribution. The terms
@@ -26,8 +26,7 @@
 /* ftp can use this as well */
 CURLcode Curl_proxyCONNECT(struct connectdata *conn,
                            int tunnelsocket,
-                           const char *hostname, int remote_port,
-                           bool blocking);
+                           const char *hostname, int remote_port);
 
 /* Default proxy timeout in milliseconds */
 #define PROXY_TIMEOUT (3600*1000)

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



reply via email to

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