ze-filter  (ze-filter-0.8.0-develop-180218)
ze-dns.c File Reference
#include <ze-sys.h>
#include "ze-libjc.h"
#include "ze-dns.h"

Go to the source code of this file.

Classes

struct  stot
 

Macros

#define MAXHOSTNAMELEN   256
 
#define DNS_INIT_LOCK()
 
#define DNS_INIT_UNLOCK()
 
#define DNS_LOCK()   MUTEX_LOCK(&mutex)
 
#define DNS_UNLOCK()   MUTEX_UNLOCK(&mutex)
 
#define DNS_DEBUG   1
 
#define STATPM   _res
 
#define MAC_H_ERRNO   h_errno
 
#define SM_SET_H_ERRNO(i)   {MAC_H_ERRNO = (i);}
 
#define jc_res_query(st, a, b, c, d, e)   res_query(a, b, c, d, e)
 
#define jc_res_init(st)
 
#define jc_res_close()
 

Functions

int dns_string_to_type (char *name) const
 
const char * dns_type_to_string (int type)
 
void dns_free_data (DNS_REPLY_T *r)
 
int parse_dns_reply (DNS_REPLY_T *reply, unsigned char *data, long len)
 
int dns_lookup (char *domain, const char *type_name, time_t retrans, int retry, DNS_REPLY_T *r) const
 

Macro Definition Documentation

◆ DNS_DEBUG

#define DNS_DEBUG   1

Definition at line 474 of file ze-dns.c.

◆ DNS_INIT_LOCK

#define DNS_INIT_LOCK ( )

Definition at line 459 of file ze-dns.c.

◆ DNS_INIT_UNLOCK

#define DNS_INIT_UNLOCK ( )

Definition at line 460 of file ze-dns.c.

◆ DNS_LOCK

#define DNS_LOCK ( )    MUTEX_LOCK(&mutex)

Definition at line 464 of file ze-dns.c.

◆ DNS_UNLOCK

#define DNS_UNLOCK ( )    MUTEX_UNLOCK(&mutex)

Definition at line 465 of file ze-dns.c.

◆ jc_res_close

#define jc_res_close ( )

Definition at line 508 of file ze-dns.c.

◆ jc_res_init

#define jc_res_init (   st)

Definition at line 500 of file ze-dns.c.

◆ jc_res_query

#define jc_res_query (   st,
  a,
  b,
  c,
  d,
 
)    res_query(a, b, c, d, e)

Definition at line 492 of file ze-dns.c.

◆ MAC_H_ERRNO

#define MAC_H_ERRNO   h_errno

Definition at line 482 of file ze-dns.c.

◆ MAXHOSTNAMELEN

#define MAXHOSTNAMELEN   256

Definition at line 74 of file ze-dns.c.

◆ SM_SET_H_ERRNO

#define SM_SET_H_ERRNO (   i)    {MAC_H_ERRNO = (i);}

Definition at line 485 of file ze-dns.c.

◆ STATPM

#define STATPM   _res

Definition at line 481 of file ze-dns.c.

Function Documentation

◆ dns_lookup()

int dns_lookup ( char *  domain,
const char *  type_name,
time_t  retrans,
int  retry,
DNS_REPLY_T r 
) const

Definition at line 640 of file ze-dns.c.

◆ dns_string_to_type()

int dns_string_to_type ( char *  name) const

Definition at line 137 of file ze-dns.c.

◆ parse_dns_reply()

int parse_dns_reply ( DNS_REPLY_T reply,
unsigned char *  data,
long  len 
)

Definition at line 237 of file ze-dns.c.