123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116 |
- #define __FORCE_GLIBC__
- #include <features.h>
- #include <rpc/types.h>
- #include <rpc/xdr.h>
- #include <rpc/pmap_prot.h>
- bool_t xdr_pmaplist(xdrs, rp)
- register XDR *xdrs;
- register struct pmaplist **rp;
- {
-
- bool_t more_elements;
- register int freeing = (xdrs->x_op == XDR_FREE);
- register struct pmaplist **next;
- #warning expect "next" might be unitialized
- while (TRUE) {
- more_elements = (bool_t) (*rp != NULL);
- if (!xdr_bool(xdrs, &more_elements))
- return (FALSE);
- if (!more_elements)
- return (TRUE);
-
- if (freeing)
- next = &((*rp)->pml_next);
- if (!xdr_reference(xdrs, (caddr_t *) rp,
- (u_int) sizeof(struct pmaplist), (xdrproc_t) xdr_pmap))
- return (FALSE);
- rp = (freeing) ? next : &((*rp)->pml_next);
- }
- }
|