# HG changeset patch # User masneyb # Date 1094603655 0 # Node ID 34a3f10d8baeaee1aa69eb125bb738dfdacdba8c # Parent 5d13fa48c275c7fc14810ff00d1574c48e1b3783 2004-9-6 Brian Masney * lib/gftp.h lib/misc.c lib/protocols.c lib/rfc959.c - fixes for hosts that have IPv6 and IPv4 hostnames and a IPv6 connection cannot be made * lib/rfc2068.c - removed unused variable diff -r 5d13fa48c275 -r 34a3f10d8bae ChangeLog --- a/ChangeLog Wed Sep 08 00:18:10 2004 +0000 +++ b/ChangeLog Wed Sep 08 00:34:15 2004 +0000 @@ -1,4 +1,10 @@ 2004-9-6 Brian Masney + * lib/gftp.h lib/misc.c lib/protocols.c lib/rfc959.c - fixes for + hosts that have IPv6 and IPv4 hostnames and a IPv6 connection cannot + be made + + * lib/rfc2068.c - removed unused variable + * lib/protocols.c lib/sshv2.c lib/sslcommon.c - cleanups to the functions that write/read to/from the network. Retry the operation if EAGAIN is returned @@ -2801,7 +2807,7 @@ * cvsclean - added this script - * *.[ch] - added $Id: ChangeLog,v 1.317 2004/09/08 00:18:09 masneyb Exp $ tags + * *.[ch] - added $Id: ChangeLog,v 1.318 2004/09/08 00:34:15 masneyb Exp $ tags * debian/* - updated files from Debian maintainer diff -r 5d13fa48c275 -r 34a3f10d8bae lib/gftp.h --- a/lib/gftp.h Wed Sep 08 00:18:10 2004 +0000 +++ b/lib/gftp.h Wed Sep 08 00:34:15 2004 +0000 @@ -379,6 +379,7 @@ struct hostent host, *hostp; #endif + int ai_family; int server_type; /* The type of server we are connected to. See GFTP_DIRTYPE_* above */ unsigned int free_hostp : 1, /* Should we free the hostp structure diff -r 5d13fa48c275 -r 34a3f10d8bae lib/misc.c --- a/lib/misc.c Wed Sep 08 00:18:10 2004 +0000 +++ b/lib/misc.c Wed Sep 08 00:34:15 2004 +0000 @@ -587,6 +587,7 @@ newreq->port = req->port; newreq->use_proxy = req->use_proxy; newreq->logging_function = req->logging_function; + newreq->ai_family = req->ai_family; newreq->free_hostp = 0; newreq->hostp = NULL; diff -r 5d13fa48c275 -r 34a3f10d8bae lib/protocols.c --- a/lib/protocols.c Wed Sep 08 00:18:10 2004 +0000 +++ b/lib/protocols.c Wed Sep 08 00:34:15 2004 +0000 @@ -2159,6 +2159,8 @@ close (sock); continue; } + + request->ai_family = res->ai_family; break; } @@ -2185,6 +2187,7 @@ g_return_val_if_fail (sock != -1, GFTP_EFATAL); + request->ai_family = AF_INET; if ((sock = socket (AF_INET, SOCK_STREAM, IPPROTO_TCP)) < 0) { request->logging_function (gftp_logging_error, request, diff -r 5d13fa48c275 -r 34a3f10d8bae lib/rfc2068.c --- a/lib/rfc2068.c Wed Sep 08 00:18:10 2004 +0000 +++ b/lib/rfc2068.c Wed Sep 08 00:34:15 2004 +0000 @@ -705,7 +705,6 @@ void *read_ptr_pos; ssize_t retval; size_t sret; - int ret; params = request->protocol_data; params->read_ref_cnt++; diff -r 5d13fa48c275 -r 34a3f10d8bae lib/rfc959.c --- a/lib/rfc959.c Wed Sep 08 00:18:10 2004 +0000 +++ b/lib/rfc959.c Wed Sep 08 00:34:15 2004 +0000 @@ -937,7 +937,7 @@ g_return_val_if_fail (request->datafd > 0, GFTP_EFATAL); #ifdef HAVE_IPV6 - if (GFTP_GET_AI_FAMILY(request) == AF_INET6) + if (request->ai_family == AF_INET6) return (rfc959_ipv6_data_connection_new (request)); else return (rfc959_ipv4_data_connection_new (request));