Deleted Added
full compact
rpcb_st_xdr.c (258578) rpcb_st_xdr.c (288113)
1/* $NetBSD: rpcb_st_xdr.c,v 1.3 2000/07/14 08:40:42 fvdl Exp $ */
2
3/*-
4 * Copyright (c) 2009, Sun Microsystems, Inc.
5 * All rights reserved.
6 *
7 * Redistribution and use in source and binary forms, with or without
8 * modification, are permitted provided that the following conditions are met:

--- 24 unchanged lines hidden (view full) ---

33 */
34
35/*
36 * This file was generated from rpcb_prot.x, but includes only those
37 * routines used with the rpcbind stats facility.
38 */
39
40#include <sys/cdefs.h>
1/* $NetBSD: rpcb_st_xdr.c,v 1.3 2000/07/14 08:40:42 fvdl Exp $ */
2
3/*-
4 * Copyright (c) 2009, Sun Microsystems, Inc.
5 * All rights reserved.
6 *
7 * Redistribution and use in source and binary forms, with or without
8 * modification, are permitted provided that the following conditions are met:

--- 24 unchanged lines hidden (view full) ---

33 */
34
35/*
36 * This file was generated from rpcb_prot.x, but includes only those
37 * routines used with the rpcbind stats facility.
38 */
39
40#include <sys/cdefs.h>
41__FBSDID("$FreeBSD: head/lib/libc/rpc/rpcb_st_xdr.c 258578 2013-11-25 19:04:36Z hrs $");
41__FBSDID("$FreeBSD: head/lib/libc/rpc/rpcb_st_xdr.c 288113 2015-09-22 15:40:07Z rodrigc $");
42
43#include "namespace.h"
44#include <rpc/rpc.h>
45#include "un-namespace.h"
46
47/* Link list of all the stats about getport and getaddr */
48
49bool_t
42
43#include "namespace.h"
44#include <rpc/rpc.h>
45#include "un-namespace.h"
46
47/* Link list of all the stats about getport and getaddr */
48
49bool_t
50xdr_rpcbs_addrlist(xdrs, objp)
51 XDR *xdrs;
52 rpcbs_addrlist *objp;
50xdr_rpcbs_addrlist(XDR *xdrs, rpcbs_addrlist *objp)
53{
54 struct rpcbs_addrlist **pnext;
55
56 if (!xdr_u_int32_t(xdrs, &objp->prog)) {
57 return (FALSE);
58 }
59 if (!xdr_u_int32_t(xdrs, &objp->vers)) {
60 return (FALSE);

--- 17 unchanged lines hidden (view full) ---

78 }
79
80 return (TRUE);
81}
82
83/* Link list of all the stats about rmtcall */
84
85bool_t
51{
52 struct rpcbs_addrlist **pnext;
53
54 if (!xdr_u_int32_t(xdrs, &objp->prog)) {
55 return (FALSE);
56 }
57 if (!xdr_u_int32_t(xdrs, &objp->vers)) {
58 return (FALSE);

--- 17 unchanged lines hidden (view full) ---

76 }
77
78 return (TRUE);
79}
80
81/* Link list of all the stats about rmtcall */
82
83bool_t
86xdr_rpcbs_rmtcalllist(xdrs, objp)
87 XDR *xdrs;
88 rpcbs_rmtcalllist *objp;
84xdr_rpcbs_rmtcalllist(XDR *xdrs, rpcbs_rmtcalllist *objp)
89{
90 int32_t *buf;
91 struct rpcbs_rmtcalllist **pnext;
92
93 if (xdrs->x_op == XDR_ENCODE) {
94 buf = XDR_INLINE(xdrs, 6 * BYTES_PER_XDR_UNIT);
95 if (buf == NULL) {
96 if (!xdr_u_int32_t(xdrs, &objp->prog)) {

--- 96 unchanged lines hidden (view full) ---

193 sizeof (rpcbs_rmtcalllist),
194 (xdrproc_t)xdr_rpcbs_rmtcalllist)) {
195 return (FALSE);
196 }
197 return (TRUE);
198}
199
200bool_t
85{
86 int32_t *buf;
87 struct rpcbs_rmtcalllist **pnext;
88
89 if (xdrs->x_op == XDR_ENCODE) {
90 buf = XDR_INLINE(xdrs, 6 * BYTES_PER_XDR_UNIT);
91 if (buf == NULL) {
92 if (!xdr_u_int32_t(xdrs, &objp->prog)) {

--- 96 unchanged lines hidden (view full) ---

189 sizeof (rpcbs_rmtcalllist),
190 (xdrproc_t)xdr_rpcbs_rmtcalllist)) {
191 return (FALSE);
192 }
193 return (TRUE);
194}
195
196bool_t
201xdr_rpcbs_proc(xdrs, objp)
202 XDR *xdrs;
203 rpcbs_proc objp;
197xdr_rpcbs_proc(XDR *xdrs, rpcbs_proc objp)
204{
205 if (!xdr_vector(xdrs, (char *)(void *)objp, RPCBSTAT_HIGHPROC,
206 sizeof (int), (xdrproc_t)xdr_int)) {
207 return (FALSE);
208 }
209 return (TRUE);
210}
211
212bool_t
198{
199 if (!xdr_vector(xdrs, (char *)(void *)objp, RPCBSTAT_HIGHPROC,
200 sizeof (int), (xdrproc_t)xdr_int)) {
201 return (FALSE);
202 }
203 return (TRUE);
204}
205
206bool_t
213xdr_rpcbs_addrlist_ptr(xdrs, objp)
214 XDR *xdrs;
215 rpcbs_addrlist_ptr *objp;
207xdr_rpcbs_addrlist_ptr(XDR *xdrs, rpcbs_addrlist_ptr *objp)
216{
217 if (!xdr_pointer(xdrs, (char **)objp, sizeof (rpcbs_addrlist),
218 (xdrproc_t)xdr_rpcbs_addrlist)) {
219 return (FALSE);
220 }
221 return (TRUE);
222}
223
224bool_t
208{
209 if (!xdr_pointer(xdrs, (char **)objp, sizeof (rpcbs_addrlist),
210 (xdrproc_t)xdr_rpcbs_addrlist)) {
211 return (FALSE);
212 }
213 return (TRUE);
214}
215
216bool_t
225xdr_rpcbs_rmtcalllist_ptr(xdrs, objp)
226 XDR *xdrs;
227 rpcbs_rmtcalllist_ptr *objp;
217xdr_rpcbs_rmtcalllist_ptr(XDR *xdrs, rpcbs_rmtcalllist_ptr *objp)
228{
229 if (!xdr_pointer(xdrs, (char **)objp, sizeof (rpcbs_rmtcalllist),
230 (xdrproc_t)xdr_rpcbs_rmtcalllist)) {
231 return (FALSE);
232 }
233 return (TRUE);
234}
235
236bool_t
218{
219 if (!xdr_pointer(xdrs, (char **)objp, sizeof (rpcbs_rmtcalllist),
220 (xdrproc_t)xdr_rpcbs_rmtcalllist)) {
221 return (FALSE);
222 }
223 return (TRUE);
224}
225
226bool_t
237xdr_rpcb_stat(xdrs, objp)
238 XDR *xdrs;
239 rpcb_stat *objp;
227xdr_rpcb_stat(XDR *xdrs, rpcb_stat *objp)
240{
241
242 if (!xdr_rpcbs_proc(xdrs, objp->info)) {
243 return (FALSE);
244 }
245 if (!xdr_int(xdrs, &objp->setinfo)) {
246 return (FALSE);
247 }

--- 9 unchanged lines hidden (view full) ---

257 return (TRUE);
258}
259
260/*
261 * One rpcb_stat structure is returned for each version of rpcbind
262 * being monitored.
263 */
264bool_t
228{
229
230 if (!xdr_rpcbs_proc(xdrs, objp->info)) {
231 return (FALSE);
232 }
233 if (!xdr_int(xdrs, &objp->setinfo)) {
234 return (FALSE);
235 }

--- 9 unchanged lines hidden (view full) ---

245 return (TRUE);
246}
247
248/*
249 * One rpcb_stat structure is returned for each version of rpcbind
250 * being monitored.
251 */
252bool_t
265xdr_rpcb_stat_byvers(xdrs, objp)
266 XDR *xdrs;
267 rpcb_stat_byvers objp;
253xdr_rpcb_stat_byvers(XDR *xdrs, rpcb_stat_byvers objp)
268{
269 if (!xdr_vector(xdrs, (char *)(void *)objp, RPCBVERS_STAT,
270 sizeof (rpcb_stat), (xdrproc_t)xdr_rpcb_stat)) {
271 return (FALSE);
272 }
273 return (TRUE);
274}
254{
255 if (!xdr_vector(xdrs, (char *)(void *)objp, RPCBVERS_STAT,
256 sizeof (rpcb_stat), (xdrproc_t)xdr_rpcb_stat)) {
257 return (FALSE);
258 }
259 return (TRUE);
260}