diff options
Diffstat (limited to 'lib/librpcsvc/yp.x')
-rw-r--r-- | lib/librpcsvc/yp.x | 64 |
1 files changed, 33 insertions, 31 deletions
diff --git a/lib/librpcsvc/yp.x b/lib/librpcsvc/yp.x index 9e81df14976..d384bf6ac2e 100644 --- a/lib/librpcsvc/yp.x +++ b/lib/librpcsvc/yp.x @@ -1,4 +1,4 @@ -/* $OpenBSD: yp.x,v 1.3 2003/02/13 05:54:39 maja Exp $ */ +/* $OpenBSD: yp.x,v 1.4 2003/07/10 07:51:13 deraadt Exp $ */ /* * Sun RPC is a product of Sun Microsystems, Inc. and is provided for @@ -7,23 +7,23 @@ * may copy or modify Sun RPC without charge, but are not authorized * to license or distribute it to anyone else except as part of a product or * program developed by the user. - * + * * SUN RPC IS PROVIDED AS IS WITH NO WARRANTIES OF ANY KIND INCLUDING THE * WARRANTIES OF DESIGN, MERCHANTIBILITY AND FITNESS FOR A PARTICULAR * PURPOSE, OR ARISING FROM A COURSE OF DEALING, USAGE OR TRADE PRACTICE. - * + * * Sun RPC is provided with no support and without any obligation on the * part of Sun Microsystems, Inc. to assist in its use, correction, * modification or enhancement. - * + * * SUN MICROSYSTEMS, INC. SHALL HAVE NO LIABILITY WITH RESPECT TO THE * INFRINGEMENT OF COPYRIGHTS, TRADE SECRETS OR ANY PATENTS BY SUN RPC * OR ANY PART THEREOF. - * + * * In no event will Sun Microsystems, Inc. be liable for any lost revenue * or profits or other special, indirect and consequential damages, even if * Sun has been advised of the possibility of such damages. - * + * * Sun Microsystems, Inc. * 2550 Garcia Avenue * Mountain View, California 94043 @@ -36,7 +36,7 @@ #ifndef RPC_HDR %#ifndef lint %/*static char sccsid[] = "from: @(#)yp.x 2.1 88/08/01 4.0 RPCSRC";*/ -%static char rcsid[] = "$OpenBSD: yp.x,v 1.3 2003/02/13 05:54:39 maja Exp $"; +%static char rcsid[] = "$OpenBSD: yp.x,v 1.4 2003/07/10 07:51:13 deraadt Exp $"; %#endif /* not lint */ #endif @@ -89,7 +89,7 @@ typedef opaque valdat<YPMAXRECORD>; struct ypmap_parms { - domainname domain; + domainname domain; mapname map; unsigned int ordernum; peername peer; @@ -102,10 +102,10 @@ struct ypreq_key { }; struct ypreq_nokey { - domainname domain; + domainname domain; mapname map; }; - + struct ypreq_xfr { ypmap_parms map_parms; unsigned int transid; @@ -132,7 +132,7 @@ struct ypresp_key_val { struct ypresp_master { - ypstat stat; + ypstat stat; peername peer; }; @@ -191,31 +191,31 @@ struct yppushresp_xfr { * Response structure and overall result status codes. Success and failure * represent two separate response message types. */ - + enum ypbind_resptype { - YPBIND_SUCC_VAL = 1, + YPBIND_SUCC_VAL = 1, YPBIND_FAIL_VAL = 2 }; - + struct ypbind_binding { - opaque ypbind_binding_addr[4]; /* In network order */ - opaque ypbind_binding_port[2]; /* In network order */ -}; + opaque ypbind_binding_addr[4]; /* In network order */ + opaque ypbind_binding_port[2]; /* In network order */ +}; union ypbind_resp switch (ypbind_resptype ypbind_status) { case YPBIND_FAIL_VAL: - unsigned ypbind_error; + unsigned ypbind_error; case YPBIND_SUCC_VAL: - ypbind_binding ypbind_bindinfo; -}; + ypbind_binding ypbind_bindinfo; +}; /* Detailed failure reason codes for response field ypbind_error*/ - + const YPBIND_ERR_ERR = 1; /* Internal error */ const YPBIND_ERR_NOSERV = 2; /* No bound server for passed domain */ const YPBIND_ERR_RESC = 3; /* System resource allocation failure */ - - + + /* * Request data structure for ypbind "Set domain" procedure. */ @@ -231,11 +231,11 @@ struct ypbind_setdom { */ program YPPROG { version YPVERS { - void + void YPPROC_NULL(void) = 0; - bool - YPPROC_DOMAIN(domainname) = 1; + bool + YPPROC_DOMAIN(domainname) = 1; bool YPPROC_DOMAIN_NONACK(domainname) = 2; @@ -243,14 +243,14 @@ program YPPROG { ypresp_val YPPROC_MATCH(ypreq_key) = 3; - ypresp_key_val + ypresp_key_val #ifdef STUPID_SUN_BUG /* should be ypreq_nokey */ YPPROC_FIRST(ypreq_key) = 4; #else YPPROC_FIRST(ypreq_nokey) = 4; #endif - ypresp_key_val + ypresp_key_val YPPROC_NEXT(ypreq_key) = 5; ypresp_xfr @@ -268,12 +268,14 @@ program YPPROG { ypresp_order YPPROC_ORDER(ypreq_nokey) = 10; - ypresp_maplist + ypresp_maplist YPPROC_MAPLIST(domainname) = 11; } = 2; } = 100004; +%bool_t xdr_ypresp_all_seq(XDR *, u_long *); + /* * YPPUSHPROC_XFRRESP is the callback routine for result of YPPROC_XFR */ @@ -282,7 +284,7 @@ program YPPUSH_XFRRESPPROG { void YPPUSHPROC_NULL(void) = 0; - yppushresp_xfr + yppushresp_xfr YPPUSHPROC_XFRRESP(void) = 1; } = 1; } = 0x40000000; /* transient: could be anything up to 0x5fffffff */ @@ -295,7 +297,7 @@ program YPBINDPROG { version YPBINDVERS { void YPBINDPROC_NULL(void) = 0; - + ypbind_resp YPBINDPROC_DOMAIN(domainname) = 1; |