File: ypupdate_xdr.c

package info (click to toggle)
nfs-utils 1%3A1.0.6-3.1
  • links: PTS
  • area: main
  • in suites: sarge
  • size: 1,532 kB
  • ctags: 1,845
  • sloc: ansic: 16,107; sh: 3,129; makefile: 272
file content (29 lines) | stat: -rw-r--r-- 710 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
/*
 * support/nfs/ypupdate_xdr.c
 *
 * This file contains the XDR code for the ypupdate protocol.
 *
 * Copyright (C) 1995, 1996 Olaf Kirch <okir@monad.swb.de>
 */

#include "config.h"

#include <ypupdate.h>

bool_t
xdr_ypupdate_args(XDR *xdrs, ypupdate_args *objp)
{
	 return xdr_string(xdrs, &objp->mapname, MAXMAPNAMELEN) &&
	 	xdr_bytes(xdrs, &objp->key.yp_buf_val,
				&objp->key.yp_buf_len, MAXYPDATALEN) &&
	 	xdr_bytes(xdrs, &objp->datum.yp_buf_val,
				&objp->datum.yp_buf_len, MAXYPDATALEN);
}

bool_t
xdr_ypdelete_args(XDR *xdrs, ypdelete_args *objp)
{
	 return xdr_string(xdrs, &objp->mapname, MAXMAPNAMELEN) &&
	 	xdr_bytes(xdrs, &objp->key.yp_buf_val,
				&objp->key.yp_buf_len, MAXYPDATALEN);
}