projects
/
privoxy.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Remove #39. jarfile support got garbage collected before the 3.0.12 release.
[privoxy.git]
/
jbsockets.c
diff --git
a/jbsockets.c
b/jbsockets.c
index
103a2b9
..
d25ed88
100644
(file)
--- a/
jbsockets.c
+++ b/
jbsockets.c
@@
-1,4
+1,4
@@
-const char jbsockets_rcs[] = "$Id: jbsockets.c,v 1.9
5 2011/03/27 14:03:25
fabiankeil Exp $";
+const char jbsockets_rcs[] = "$Id: jbsockets.c,v 1.9
7 2011/03/27 14:04:10
fabiankeil Exp $";
/*********************************************************************
*
* File : $Source: /cvsroot/ijbswa/current/jbsockets.c,v $
/*********************************************************************
*
* File : $Source: /cvsroot/ijbswa/current/jbsockets.c,v $
@@
-157,7
+157,8
@@
jb_socket connect_to(const char *host, int portnum, struct client_state *csp)
#else
fd = no_rfc2553_connect_to(host, portnum, csp);
#endif
#else
fd = no_rfc2553_connect_to(host, portnum, csp);
#endif
- if ((fd != JB_INVALID_SOCKET) || (errno != EINVAL))
+ if ((fd != JB_INVALID_SOCKET) || (errno == EINVAL)
+ || ((csp->fwd->forward_host == NULL) && (csp->fwd->type == SOCKS_NONE)))
{
break;
}
{
break;
}
@@
-232,6
+233,7
@@
static jb_socket rfc2553_connect_to(const char *host, int portnum, struct client
csp->http->host_ip_addr_str = malloc(NI_MAXHOST);
if (NULL == csp->http->host_ip_addr_str)
{
csp->http->host_ip_addr_str = malloc(NI_MAXHOST);
if (NULL == csp->http->host_ip_addr_str)
{
+ freeaddrinfo(result);
log_error(LOG_LEVEL_ERROR,
"Out of memory while getting the server IP address.");
return JB_INVALID_SOCKET;
log_error(LOG_LEVEL_ERROR,
"Out of memory while getting the server IP address.");
return JB_INVALID_SOCKET;