annotate fake-rfc2553.h @ 299:740e782679be ucc-axis-hack

Various changes to compile+kind of run on UCC's axis board. Note that fprintf(stdin -> printf( accounts for many of the changes
author Matt Johnston <matt@ucc.asn.au>
date Sat, 25 Mar 2006 12:57:09 +0000
parents 86725004a0ea
children dc6173e09ff7
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
67
86725004a0ea fake-rfc stuff
Matt Johnston <matt@ucc.asn.au>
parents: 64
diff changeset
1 /* Taken from OpenSSH 3.8.1p1 */
86725004a0ea fake-rfc stuff
Matt Johnston <matt@ucc.asn.au>
parents: 64
diff changeset
2
86725004a0ea fake-rfc stuff
Matt Johnston <matt@ucc.asn.au>
parents: 64
diff changeset
3 /* $.Id: fake-rfc2553.h,v 1.9 2004/03/10 10:06:33 dtucker Exp $ */
64
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
4
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
5 /*
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
6 * Copyright (C) 2000-2003 Damien Miller. All rights reserved.
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
7 * Copyright (C) 1999 WIDE Project. All rights reserved.
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
8 *
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
9 * Redistribution and use in source and binary forms, with or without
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
10 * modification, are permitted provided that the following conditions
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
11 * are met:
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
12 * 1. Redistributions of source code must retain the above copyright
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
13 * notice, this list of conditions and the following disclaimer.
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
14 * 2. Redistributions in binary form must reproduce the above copyright
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
15 * notice, this list of conditions and the following disclaimer in the
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
16 * documentation and/or other materials provided with the distribution.
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
17 * 3. Neither the name of the project nor the names of its contributors
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
18 * may be used to endorse or promote products derived from this software
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
19 * without specific prior written permission.
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
20 *
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
21 * THIS SOFTWARE IS PROVIDED BY THE PROJECT AND CONTRIBUTORS ``AS IS'' AND
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
22 * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
23 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
24 * ARE DISCLAIMED. IN NO EVENT SHALL THE PROJECT OR CONTRIBUTORS BE LIABLE
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
25 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
26 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
27 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
28 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
29 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
30 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
31 * SUCH DAMAGE.
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
32 */
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
33
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
34 /*
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
35 * Pseudo-implementation of RFC2553 name / address resolution functions
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
36 *
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
37 * But these functions are not implemented correctly. The minimum subset
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
38 * is implemented for ssh use only. For example, this routine assumes
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
39 * that ai_family is AF_INET. Don't use it for another purpose.
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
40 */
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
41
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
42 #ifndef _FAKE_RFC2553_H
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
43 #define _FAKE_RFC2553_H
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
44
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
45 #include "includes.h"
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
46
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
47 /*
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
48 * First, socket and INET6 related definitions
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
49 */
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
50 #ifndef HAVE_STRUCT_SOCKADDR_STORAGE
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
51 # define _SS_MAXSIZE 128 /* Implementation specific max size */
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
52 # define _SS_PADSIZE (_SS_MAXSIZE - sizeof (struct sockaddr))
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
53 struct sockaddr_storage {
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
54 struct sockaddr ss_sa;
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
55 char __ss_pad2[_SS_PADSIZE];
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
56 };
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
57 # define ss_family ss_sa.sa_family
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
58 #endif /* !HAVE_STRUCT_SOCKADDR_STORAGE */
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
59
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
60 #ifndef IN6_IS_ADDR_LOOPBACK
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
61 # define IN6_IS_ADDR_LOOPBACK(a) \
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
62 (((u_int32_t *)(a))[0] == 0 && ((u_int32_t *)(a))[1] == 0 && \
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
63 ((u_int32_t *)(a))[2] == 0 && ((u_int32_t *)(a))[3] == htonl(1))
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
64 #endif /* !IN6_IS_ADDR_LOOPBACK */
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
65
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
66 #ifndef HAVE_STRUCT_IN6_ADDR
299
740e782679be Various changes to compile+kind of run on UCC's axis board.
Matt Johnston <matt@ucc.asn.au>
parents: 67
diff changeset
67 // struct in6_addr {
740e782679be Various changes to compile+kind of run on UCC's axis board.
Matt Johnston <matt@ucc.asn.au>
parents: 67
diff changeset
68 // u_int8_t s6_addr[16];
740e782679be Various changes to compile+kind of run on UCC's axis board.
Matt Johnston <matt@ucc.asn.au>
parents: 67
diff changeset
69 // };
64
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
70 #endif /* !HAVE_STRUCT_IN6_ADDR */
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
71
299
740e782679be Various changes to compile+kind of run on UCC's axis board.
Matt Johnston <matt@ucc.asn.au>
parents: 67
diff changeset
72 // #ifndef HAVE_STRUCT_SOCKADDR_IN6
740e782679be Various changes to compile+kind of run on UCC's axis board.
Matt Johnston <matt@ucc.asn.au>
parents: 67
diff changeset
73 // struct sockaddr_in6 {
740e782679be Various changes to compile+kind of run on UCC's axis board.
Matt Johnston <matt@ucc.asn.au>
parents: 67
diff changeset
74 // unsigned short sin6_family;
740e782679be Various changes to compile+kind of run on UCC's axis board.
Matt Johnston <matt@ucc.asn.au>
parents: 67
diff changeset
75 // u_int16_t sin6_port;
740e782679be Various changes to compile+kind of run on UCC's axis board.
Matt Johnston <matt@ucc.asn.au>
parents: 67
diff changeset
76 // u_int32_t sin6_flowinfo;
740e782679be Various changes to compile+kind of run on UCC's axis board.
Matt Johnston <matt@ucc.asn.au>
parents: 67
diff changeset
77 // struct in6_addr sin6_addr;
740e782679be Various changes to compile+kind of run on UCC's axis board.
Matt Johnston <matt@ucc.asn.au>
parents: 67
diff changeset
78 // };
740e782679be Various changes to compile+kind of run on UCC's axis board.
Matt Johnston <matt@ucc.asn.au>
parents: 67
diff changeset
79 // #endif /* !HAVE_STRUCT_SOCKADDR_IN6 */
64
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
80
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
81 #ifndef AF_INET6
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
82 /* Define it to something that should never appear */
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
83 #define AF_INET6 AF_MAX
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
84 #endif
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
85
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
86 /*
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
87 * Next, RFC2553 name / address resolution API
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
88 */
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
89
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
90 #ifndef NI_NUMERICHOST
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
91 # define NI_NUMERICHOST (1)
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
92 #endif
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
93 #ifndef NI_NAMEREQD
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
94 # define NI_NAMEREQD (1<<1)
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
95 #endif
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
96 #ifndef NI_NUMERICSERV
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
97 # define NI_NUMERICSERV (1<<2)
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
98 #endif
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
99
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
100 #ifndef AI_PASSIVE
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
101 # define AI_PASSIVE (1)
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
102 #endif
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
103 #ifndef AI_CANONNAME
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
104 # define AI_CANONNAME (1<<1)
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
105 #endif
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
106 #ifndef AI_NUMERICHOST
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
107 # define AI_NUMERICHOST (1<<2)
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
108 #endif
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
109
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
110 #ifndef NI_MAXSERV
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
111 # define NI_MAXSERV 32
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
112 #endif /* !NI_MAXSERV */
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
113 #ifndef NI_MAXHOST
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
114 # define NI_MAXHOST 1025
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
115 #endif /* !NI_MAXHOST */
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
116
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
117 #ifndef EAI_NODATA
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
118 # define EAI_NODATA 1
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
119 # define EAI_MEMORY 2
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
120 # define EAI_NONAME 3
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
121 #endif
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
122
299
740e782679be Various changes to compile+kind of run on UCC's axis board.
Matt Johnston <matt@ucc.asn.au>
parents: 67
diff changeset
123 // #ifndef HAVE_STRUCT_ADDRINFO
740e782679be Various changes to compile+kind of run on UCC's axis board.
Matt Johnston <matt@ucc.asn.au>
parents: 67
diff changeset
124 // struct addrinfo {
740e782679be Various changes to compile+kind of run on UCC's axis board.
Matt Johnston <matt@ucc.asn.au>
parents: 67
diff changeset
125 // int ai_flags; /* AI_PASSIVE, AI_CANONNAME */
740e782679be Various changes to compile+kind of run on UCC's axis board.
Matt Johnston <matt@ucc.asn.au>
parents: 67
diff changeset
126 // int ai_family; /* PF_xxx */
740e782679be Various changes to compile+kind of run on UCC's axis board.
Matt Johnston <matt@ucc.asn.au>
parents: 67
diff changeset
127 // int ai_socktype; /* SOCK_xxx */
740e782679be Various changes to compile+kind of run on UCC's axis board.
Matt Johnston <matt@ucc.asn.au>
parents: 67
diff changeset
128 // int ai_protocol; /* 0 or IPPROTO_xxx for IPv4 and IPv6 */
740e782679be Various changes to compile+kind of run on UCC's axis board.
Matt Johnston <matt@ucc.asn.au>
parents: 67
diff changeset
129 // size_t ai_addrlen; /* length of ai_addr */
740e782679be Various changes to compile+kind of run on UCC's axis board.
Matt Johnston <matt@ucc.asn.au>
parents: 67
diff changeset
130 // char *ai_canonname; /* canonical name for hostname */
740e782679be Various changes to compile+kind of run on UCC's axis board.
Matt Johnston <matt@ucc.asn.au>
parents: 67
diff changeset
131 // struct sockaddr *ai_addr; /* binary address */
740e782679be Various changes to compile+kind of run on UCC's axis board.
Matt Johnston <matt@ucc.asn.au>
parents: 67
diff changeset
132 // struct addrinfo *ai_next; /* next structure in linked list */
740e782679be Various changes to compile+kind of run on UCC's axis board.
Matt Johnston <matt@ucc.asn.au>
parents: 67
diff changeset
133 // };
740e782679be Various changes to compile+kind of run on UCC's axis board.
Matt Johnston <matt@ucc.asn.au>
parents: 67
diff changeset
134 // #endif /* !HAVE_STRUCT_ADDRINFO */
64
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
135
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
136 #ifndef HAVE_GETADDRINFO
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
137 #ifdef getaddrinfo
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
138 # undef getaddrinfo
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
139 #endif
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
140 #define getaddrinfo(a,b,c,d) (ssh_getaddrinfo(a,b,c,d))
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
141 int getaddrinfo(const char *, const char *,
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
142 const struct addrinfo *, struct addrinfo **);
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
143 #endif /* !HAVE_GETADDRINFO */
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
144
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
145 #if !defined(HAVE_GAI_STRERROR) && !defined(HAVE_CONST_GAI_STRERROR_PROTO)
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
146 #define gai_strerror(a) (ssh_gai_strerror(a))
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
147 char *gai_strerror(int);
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
148 #endif /* !HAVE_GAI_STRERROR */
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
149
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
150 #ifndef HAVE_FREEADDRINFO
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
151 #define freeaddrinfo(a) (ssh_freeaddrinfo(a))
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
152 void freeaddrinfo(struct addrinfo *);
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
153 #endif /* !HAVE_FREEADDRINFO */
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
154
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
155 #ifndef HAVE_GETNAMEINFO
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
156 #define getnameinfo(a,b,c,d,e,f,g) (ssh_getnameinfo(a,b,c,d,e,f,g))
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
157 int getnameinfo(const struct sockaddr *, size_t, char *, size_t,
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
158 char *, size_t, int);
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
159 #endif /* !HAVE_GETNAMEINFO */
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
160
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
161 #endif /* !_FAKE_RFC2553_H */
efb5e0b335cf TCP forwarding works.
Matt Johnston <matt@ucc.asn.au>
parents:
diff changeset
162