GCC Code Coverage Report
Directory: ./ Exec Total Coverage
File: usr.sbin/ypserv/ypserv/ypv1.c Lines: 0 28 0.0 %
Date: 2017-11-07 Branches: 0 28 0.0 %

Line Branch Exec Source
1
/*
2
 * Please do not edit this file.
3
 * It was generated using rpcgen.
4
 */
5
6
#include "ypv1.h"
7
8
bool_t
9
xdr_ypreqtype(XDR *xdrs, ypreqtype *objp)
10
{
11
12
	if (!xdr_enum(xdrs, (enum_t *)objp))
13
		return (FALSE);
14
	return (TRUE);
15
}
16
17
bool_t
18
xdr_ypresptype(XDR *xdrs, ypresptype *objp)
19
{
20
21
	if (!xdr_enum(xdrs, (enum_t *)objp))
22
		return (FALSE);
23
	return (TRUE);
24
}
25
26
bool_t
27
xdr_yprequest(XDR *xdrs, yprequest *objp)
28
{
29
30
	if (!xdr_ypreqtype(xdrs, &objp->yp_reqtype))
31
		return (FALSE);
32
	switch (objp->yp_reqtype) {
33
	case YPREQ_KEY:
34
		if (!xdr_ypreq_key(xdrs, &objp->yprequest_u.yp_req_keytype))
35
			return (FALSE);
36
		break;
37
	case YPREQ_NOKEY:
38
		if (!xdr_ypreq_nokey(xdrs, &objp->yprequest_u.yp_req_nokeytype))
39
			return (FALSE);
40
		break;
41
	case YPREQ_MAP_PARMS:
42
		if (!xdr_ypmap_parms(xdrs, &objp->yprequest_u.yp_req_map_parmstype))
43
			return (FALSE);
44
		break;
45
	default:
46
		return (FALSE);
47
	}
48
	return (TRUE);
49
}
50
51
bool_t
52
xdr_ypresponse(XDR *xdrs, ypresponse *objp)
53
{
54
55
	if (!xdr_ypresptype(xdrs, &objp->yp_resptype))
56
		return (FALSE);
57
	switch (objp->yp_resptype) {
58
	case YPRESP_VAL:
59
		if (!xdr_ypresp_val(xdrs, &objp->ypresponse_u.yp_resp_valtype))
60
			return (FALSE);
61
		break;
62
	case YPRESP_KEY_VAL:
63
		if (!xdr_ypresp_key_val(xdrs, &objp->ypresponse_u.yp_resp_key_valtype))
64
			return (FALSE);
65
		break;
66
	case YPRESP_MAP_PARMS:
67
		if (!xdr_ypmap_parms(xdrs, &objp->ypresponse_u.yp_resp_map_parmstype))
68
			return (FALSE);
69
		break;
70
	default:
71
		return (FALSE);
72
	}
73
	return (TRUE);
74
}