Mercurial > gftp.yaz
comparison lib/gftp.h @ 952:a490d94a5b8e
2008-03-28 Brian Masney <masneyb@gftp.org>
* lib/Makefile.am lib/misc.c lib/socket-connect.c
lib/socket-connect-getaddrinfo.c lib/socket-connect-gethostbyname.c
lib/sockutils.c lib/gftp.h - cleaned up more of the socket functions
and split them up into their own files. Cleanups and bug fixes to the
DNS lookup code.
author | masneyb |
---|---|
date | Fri, 28 Mar 2008 11:44:36 +0000 |
parents | c7d7a081cd9c |
children | 63555c9744c2 |
comparison
equal
deleted
inserted
replaced
951:99f8858bbf02 | 952:a490d94a5b8e |
---|---|
383 int datafd, /* Data connection */ | 383 int datafd, /* Data connection */ |
384 cachefd; /* For the directory cache */ | 384 cachefd; /* For the directory cache */ |
385 int wakeup_main_thread[2]; /* FD that gets written to by the threads | 385 int wakeup_main_thread[2]; /* FD that gets written to by the threads |
386 to wakeup the parent */ | 386 to wakeup the parent */ |
387 | 387 |
388 #if defined (HAVE_GETADDRINFO) && defined (HAVE_GAI_STRERROR) | |
389 void *remote_addr; | 388 void *remote_addr; |
390 size_t remote_addr_len; | 389 size_t remote_addr_len; |
391 #endif | |
392 int ai_family; | 390 int ai_family; |
393 | 391 |
394 int server_type; /* The type of server we are connected to. | 392 int server_type; /* The type of server we are connected to. |
395 See GFTP_DIRTYPE_* above */ | 393 See GFTP_DIRTYPE_* above */ |
396 unsigned int use_proxy : 1, | 394 unsigned int use_proxy : 1, |
1008 | 1006 |
1009 int gftp_get_all_subdirs ( gftp_transfer * transfer, | 1007 int gftp_get_all_subdirs ( gftp_transfer * transfer, |
1010 void (*update_func) | 1008 void (*update_func) |
1011 ( gftp_transfer * transfer )); | 1009 ( gftp_transfer * transfer )); |
1012 | 1010 |
1013 struct hostent *r_gethostbyname ( const char *name, | |
1014 struct hostent *result_buf, | |
1015 int *h_errnop ); | |
1016 | |
1017 struct servent *r_getservbyname ( const char *name, | |
1018 const char *proto, | |
1019 /*@out@*/ struct servent *result_buf, | |
1020 int *h_errnop ); | |
1021 | |
1022 int gftp_set_config_options ( gftp_request * request ); | 1011 int gftp_set_config_options ( gftp_request * request ); |
1023 | 1012 |
1024 void print_file_list ( GList * list ); | 1013 void print_file_list ( GList * list ); |
1025 | 1014 |
1026 void gftp_swap_socks ( gftp_request * dest, | 1015 void gftp_swap_socks ( gftp_request * dest, |
1088 | 1077 |
1089 #endif | 1078 #endif |
1090 | 1079 |
1091 /* socket-connect.c */ | 1080 /* socket-connect.c */ |
1092 int gftp_connect_server ( gftp_request * request, | 1081 int gftp_connect_server ( gftp_request * request, |
1082 char *service, | |
1083 char *proxy_hostname, | |
1084 unsigned int proxy_port ); | |
1085 | |
1086 /* socket-connect-getaddrinfo.c */ | |
1087 struct addrinfo * lookup_host_with_getaddrinfo | |
1088 ( gftp_request *request, | |
1089 char *service, | |
1090 char *proxy_hostname, | |
1091 int proxy_port ); | |
1092 | |
1093 int gftp_connect_server_with_getaddrinfo | |
1094 ( gftp_request * request, | |
1095 char *service, | |
1096 char *proxy_hostname, | |
1097 unsigned int proxy_port ); | |
1098 | |
1099 /* socket-connect-gethostbyname.c */ | |
1100 int lookup_host_with_gethostbyname ( gftp_request *request, | |
1101 char *proxy_hostname, | |
1102 struct hostent *hostp ); | |
1103 | |
1104 int gftp_connect_server_legacy ( gftp_request * request, | |
1093 char *service, | 1105 char *service, |
1094 char *proxy_hostname, | 1106 char *proxy_hostname, |
1095 unsigned int proxy_port ); | 1107 unsigned int proxy_port ); |
1096 | 1108 |
1097 /* sockutils.c */ | 1109 /* sockutils.c */ |
1120 | 1132 |
1121 int gftp_fd_set_sockblocking ( gftp_request * request, | 1133 int gftp_fd_set_sockblocking ( gftp_request * request, |
1122 int fd, | 1134 int fd, |
1123 int non_blocking ); | 1135 int non_blocking ); |
1124 | 1136 |
1137 struct servent * r_getservbyname ( const char *name, | |
1138 const char *proto, | |
1139 struct servent *result_buf, | |
1140 int *h_errnop ); | |
1141 |