Mercurial > pidgin
comparison src/proxy.h @ 14181:fc92a5a7dd95
[gaim-migrate @ 16833]
Split the DNS query code out into its own file without actually
changing anything.
committer: Tailor Script <tailor@pidgin.im>
| author | Mark Doliner <mark@kingant.net> |
|---|---|
| date | Fri, 18 Aug 2006 07:20:31 +0000 |
| parents | 879bb47cff8e |
| children |
comparison
equal
deleted
inserted
replaced
| 14180:45818acef0eb | 14181:fc92a5a7dd95 |
|---|---|
| 58 | 58 |
| 59 typedef struct _GaimProxyConnectInfo GaimProxyConnectInfo; | 59 typedef struct _GaimProxyConnectInfo GaimProxyConnectInfo; |
| 60 | 60 |
| 61 typedef void (*GaimProxyConnectFunction)(gpointer data, gint source, const gchar *error_message); | 61 typedef void (*GaimProxyConnectFunction)(gpointer data, gint source, const gchar *error_message); |
| 62 | 62 |
| 63 /** | |
| 64 * The "hosts" parameter is a linked list containing pairs of | |
| 65 * one size_t addrlen and one struct sockaddr *addr. | |
| 66 */ | |
| 67 typedef void (*GaimProxyDnsConnectFunction)(GSList *hosts, gpointer data, const char *error_message); | |
| 68 | |
| 69 | 63 |
| 70 #include "account.h" | 64 #include "account.h" |
| 71 | 65 |
| 72 #ifdef __cplusplus | 66 #ifdef __cplusplus |
| 73 extern "C" { | 67 extern "C" { |
| 276 * attempt early rather than just letting the OS's TCP/IP stack | 270 * attempt early rather than just letting the OS's TCP/IP stack |
| 277 * time-out the connection. | 271 * time-out the connection. |
| 278 */ | 272 */ |
| 279 void gaim_proxy_connect_cancel(GaimProxyConnectInfo *connect_info); | 273 void gaim_proxy_connect_cancel(GaimProxyConnectInfo *connect_info); |
| 280 | 274 |
| 281 /** | |
| 282 * Do an async dns query | |
| 283 * | |
| 284 * @param hostname The hostname to resolve | |
| 285 * @param port A portnumber which is stored in the struct sockaddr | |
| 286 * @param callback Callback to call after resolving | |
| 287 * @param data Extra data for the callback function | |
| 288 * | |
| 289 * @return Zero indicates the connection is pending. Any other value indicates failure. | |
| 290 */ | |
| 291 int gaim_gethostbyname_async(const char *hostname, int port, GaimProxyDnsConnectFunction callback, gpointer data); | |
| 292 | |
| 293 /*@}*/ | 275 /*@}*/ |
| 294 | 276 |
| 295 #ifdef __cplusplus | 277 #ifdef __cplusplus |
| 296 } | 278 } |
| 297 #endif | 279 #endif |
