Print this page
remove support for non-ANSI compilation
   1 /*


   2  * Copyright 2009 Sun Microsystems, Inc.  All rights reserved.
   3  * Use is subject to license terms.
   4  *
   5  * Copyright (c) 1983, 1984, 1985, 1986, 1987, 1988, 1989 AT&T
   6  * All Rights Reserved
   7  *
   8  * Portions of this source code were derived from Berkeley
   9  * 4.3 BSD under license from the regents of the University of
  10  * California.
  11  */
  12 
  13 /*
  14  * BIND 4.9.4:
  15  */
  16 
  17 /*
  18  * Portions Copyright (c) 1993 by Digital Equipment Corporation.
  19  *
  20  * Permission to use, copy, modify, and distribute this software for any
  21  * purpose with or without fee is hereby granted, provided that the above


 113  * is new enough to contain a certain feature.
 114  */
 115 
 116 #define __RES   20090302
 117 
 118 #define RES_SET_H_ERRNO(r, x)   __h_errno_set(r, x)
 119 struct __res_state;                                     /* forward */
 120 
 121 void __h_errno_set(struct __res_state *res, int err);
 122 
 123 /*
 124  * Resolver configuration file.
 125  * Normally not present, but may contain the address of the
 126  * initial name server(s) to query and the domain search list.
 127  */
 128 
 129 #ifndef _PATH_RESCONF
 130 #define _PATH_RESCONF           "/etc/resolv.conf"
 131 #endif
 132 
 133 #ifdef __STDC__
 134 #ifndef __P
 135 #define __P(x)  x
 136 #endif
 137 #else
 138 #ifndef __P
 139 #define __P(x)  ()
 140 #endif
 141 #endif /* __STDC__ */
 142 
 143 typedef enum { res_goahead, res_nextns, res_modified, res_done, res_error }
 144         res_sendhookact;
 145 
 146 typedef res_sendhookact (*res_send_qhook)__P((struct sockaddr * const *ns,
 147                                                 const uchar_t **query,
 148                                                 int *querylen,
 149                                                 uchar_t *ans,
 150                                                 int anssiz,
 151                                                 int *resplen));
 152 
 153 typedef res_sendhookact (*res_send_rhook)__P((const struct sockaddr *ns,
 154                                                 const uchar_t *query,
 155                                                 int querylen,
 156                                                 uchar_t *ans,
 157                                                 int anssiz,
 158                                                 int *resplen));
 159 
 160 struct res_sym {
 161         int             number;    /* Identifying number, like T_MX */


   1 /*
   2  * Copyright 2014 Garrett D'Amore <garrett@damore.org>
   3  *
   4  * Copyright 2009 Sun Microsystems, Inc.  All rights reserved.
   5  * Use is subject to license terms.
   6  *
   7  * Copyright (c) 1983, 1984, 1985, 1986, 1987, 1988, 1989 AT&T
   8  * All Rights Reserved
   9  *
  10  * Portions of this source code were derived from Berkeley
  11  * 4.3 BSD under license from the regents of the University of
  12  * California.
  13  */
  14 
  15 /*
  16  * BIND 4.9.4:
  17  */
  18 
  19 /*
  20  * Portions Copyright (c) 1993 by Digital Equipment Corporation.
  21  *
  22  * Permission to use, copy, modify, and distribute this software for any
  23  * purpose with or without fee is hereby granted, provided that the above


 115  * is new enough to contain a certain feature.
 116  */
 117 
 118 #define __RES   20090302
 119 
 120 #define RES_SET_H_ERRNO(r, x)   __h_errno_set(r, x)
 121 struct __res_state;                                     /* forward */
 122 
 123 void __h_errno_set(struct __res_state *res, int err);
 124 
 125 /*
 126  * Resolver configuration file.
 127  * Normally not present, but may contain the address of the
 128  * initial name server(s) to query and the domain search list.
 129  */
 130 
 131 #ifndef _PATH_RESCONF
 132 #define _PATH_RESCONF           "/etc/resolv.conf"
 133 #endif
 134 

 135 #ifndef __P
 136 #define __P(x)  x
 137 #endif





 138 
 139 typedef enum { res_goahead, res_nextns, res_modified, res_done, res_error }
 140         res_sendhookact;
 141 
 142 typedef res_sendhookact (*res_send_qhook)__P((struct sockaddr * const *ns,
 143                                                 const uchar_t **query,
 144                                                 int *querylen,
 145                                                 uchar_t *ans,
 146                                                 int anssiz,
 147                                                 int *resplen));
 148 
 149 typedef res_sendhookact (*res_send_rhook)__P((const struct sockaddr *ns,
 150                                                 const uchar_t *query,
 151                                                 int querylen,
 152                                                 uchar_t *ans,
 153                                                 int anssiz,
 154                                                 int *resplen));
 155 
 156 struct res_sym {
 157         int             number;    /* Identifying number, like T_MX */