File: asyncdns.h

package info (click to toggle)
tsdecrypt 8.1-1
  • links: PTS, VCS
  • area: main
  • in suites: wheezy
  • size: 1,084 kB
  • sloc: ansic: 13,568; makefile: 248; sh: 183
file content (22 lines) | stat: -rw-r--r-- 443 bytes parent folder | download | duplicates (4)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
/*
 * Async DNS resolver
 * Copyright (C) 2009-2010 Unix Solutions Ltd.
 *
 * Released under MIT license.
 * See LICENSE-MIT.txt for license terms.
 */

#ifndef ASYNCDNS_H
# define ASYNCDNS_H

#include <arpa/inet.h>
#include <netinet/in.h>
#include <sys/socket.h>

// Returns
//   0 on success
//   1 on error
//   2 on timeout
int async_resolve_host(char *host, int port, struct sockaddr_in *sockaddr, int msec_timeout, int *active);

#endif