xref: /titanic_50/usr/src/uts/common/rpc/rpcent.h (revision 3d729aecc03ea6ebb9bd5d56b8dccd24f57daa41)
1 /*
2  * CDDL HEADER START
3  *
4  * The contents of this file are subject to the terms of the
5  * Common Development and Distribution License, Version 1.0 only
6  * (the "License").  You may not use this file except in compliance
7  * with the License.
8  *
9  * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
10  * or http://www.opensolaris.org/os/licensing.
11  * See the License for the specific language governing permissions
12  * and limitations under the License.
13  *
14  * When distributing Covered Code, include this CDDL HEADER in each
15  * file and include the License file at usr/src/OPENSOLARIS.LICENSE.
16  * If applicable, add the following below this CDDL HEADER, with the
17  * fields enclosed by brackets "[]" replaced with your own identifying
18  * information: Portions Copyright [yyyy] [name of copyright owner]
19  *
20  * CDDL HEADER END
21  *
22  * Copyright 1991 Sun Microsystems, Inc.  All rights reserved.
23  * Use is subject to license terms.
24  */
25 /* Copyright (c) 1983, 1984, 1985, 1986, 1987, 1988, 1989 AT&T */
26 /* All Rights Reserved */
27 /*
28  * Portions of this source code were derived from Berkeley
29  * 4.3 BSD under license from the Regents of the University of
30  * California.
31  */
32 
33 /*
34  * rpcent.h,
35  * For converting rpc program numbers to names etc.
36  *
37  */
38 
39 #ifndef _RPC_RPCENT_H
40 #define	_RPC_RPCENT_H
41 
42 #pragma ident	"%Z%%M%	%I%	%E% SMI"
43 
44 #ifdef	__cplusplus
45 extern "C" {
46 #endif
47 
48 struct rpcent {
49 	char	*r_name;	/* name of server for this rpc program */
50 	char	**r_aliases;	/* alias list */
51 	int	r_number;	/* rpc program number */
52 };
53 
54 #ifdef __STDC__
55 extern struct rpcent *getrpcbyname_r
56 		(const char *,	  struct rpcent *, char *, int);
57 extern struct rpcent *getrpcbynumber_r
58 		(const int,	  struct rpcent *, char *, int);
59 extern struct rpcent *getrpcent_r(struct rpcent *, char *, int);
60 
61 /* Old interfaces that return a pointer to a static area;  MT-unsafe */
62 extern struct rpcent *getrpcbyname(const char *);
63 extern struct rpcent *getrpcbynumber(const int);
64 extern struct rpcent *getrpcent(void);
65 extern void setrpcent(const int);
66 extern void endrpcent(void);
67 #else
68 extern struct rpcent *getrpcbyname_r();
69 extern struct rpcent *getrpcbynumber_r();
70 extern struct rpcent *getrpcent_r();
71 
72 /* Old interfaces that return a pointer to a static area;  MT-unsafe */
73 extern struct rpcent *getrpcbyname();
74 extern struct rpcent *getrpcbynumber();
75 extern struct rpcent *getrpcent();
76 extern void setrpcent();
77 extern void endrpcent();
78 #endif
79 
80 #ifdef	__cplusplus
81 }
82 #endif
83 
84 #endif	/* _RPC_RPCENT_H */
85