Commit 0e6a1a44 authored by Daniel Stenberg's avatar Daniel Stenberg
Browse files

Peter Su's SOCKS4 fix

parent b8bf708d
Loading
Loading
Loading
Loading
+8 −3
Original line number Diff line number Diff line
@@ -1822,7 +1822,7 @@ ConnectionStore(struct SessionHandle *data,
*/
static int handleSock4Proxy(struct connectdata *conn)
{
  unsigned char socksreq[600]; /* room for large user/pw (255 max each) */
  unsigned char socksreq[9]; /* room for SOCKS4 request */
  int result;
  CURLcode code;
  curl_socket_t sock = conn->sock[FIRSTSOCKET];
@@ -1892,6 +1892,11 @@ static int handleSock4Proxy(struct connectdata *conn)
    }
  }

  /*
   * This is currently not supporting "Identification Protocol (RFC1413)".
   */
  socksreq[8] = 0; /* NUL ending the nonexistent userid */

  /*
   * Make connection
   */