Lines Matching +full:binary +full:- +full:coded
3 /*-
4 * SPDX-License-Identifier: BSD-3-Clause
8 * Redistribution and use in source and binary forms, with or without
14 * * Redistributions in binary form must reproduce the above
39 * These are the "generic" xdr routines used to serialize and de-serialize
54 #include "un-namespace.h"
100 switch (xdrs->x_op) { in xdr_int()
128 switch (xdrs->x_op) { in xdr_u_int()
151 * same as xdr_u_long - open coded to save a proc call!
156 switch (xdrs->x_op) { in xdr_long()
170 * same as xdr_long - open coded to save a proc call!
175 switch (xdrs->x_op) { in xdr_u_long()
189 * XDR 32-bit integers
190 * same as xdr_u_int32_t - open coded to save a proc call!
197 switch (xdrs->x_op) { in xdr_int32_t()
218 * XDR unsigned 32-bit integers
219 * same as xdr_int32_t - open coded to save a proc call!
226 switch (xdrs->x_op) { in xdr_u_int32_t()
247 * XDR unsigned 32-bit integers
248 * same as xdr_int32_t - open coded to save a proc call!
255 switch (xdrs->x_op) { in xdr_uint32_t()
283 switch (xdrs->x_op) { in xdr_short()
311 switch (xdrs->x_op) { in xdr_u_short()
333 * XDR 16-bit integers
340 switch (xdrs->x_op) { in xdr_int16_t()
361 * XDR unsigned 16-bit integers
368 switch (xdrs->x_op) { in xdr_u_int16_t()
389 * XDR unsigned 16-bit integers
396 switch (xdrs->x_op) { in xdr_uint16_t()
457 switch (xdrs->x_op) { in xdr_bool()
521 rndup = BYTES_PER_XDR_UNIT - rndup; in xdr_opaque()
523 if (xdrs->x_op == XDR_DECODE) { in xdr_opaque()
532 if (xdrs->x_op == XDR_ENCODE) { in xdr_opaque()
541 if (xdrs->x_op == XDR_FREE) { in xdr_opaque()
567 if ((nodesize > maxsize) && (xdrs->x_op != XDR_FREE)) { in xdr_bytes()
574 switch (xdrs->x_op) { in xdr_bytes()
592 if ((xdrs->x_op == XDR_DECODE) && (ret == FALSE)) { in xdr_bytes()
618 return (xdr_bytes(xdrs, &np->n_bytes, &np->n_len, MAX_NETOBJ_SZ)); in xdr_netobj()
656 for (; choices->proc != NULL_xdrproc_t; choices++) { in xdr_union()
657 if (choices->value == dscm) in xdr_union()
658 return ((*(choices->proc))(xdrs, unp)); in xdr_union()
662 * no match - execute the default xdr routine if there is one in xdr_union()
670 * Non-portable xdr primitives.
677 * xdr_string deals with "C strings" - arrays of bytes that are
692 * first deal with the length since xdr strings are counted-strings in xdr_string()
694 switch (xdrs->x_op) { in xdr_string()
717 switch (xdrs->x_op) { in xdr_string()
736 if ((xdrs->x_op == XDR_DECODE) && (ret == FALSE)) { in xdr_string()
765 * are in the "non-portable" section because they require that a `long long'
766 * be a 64-bit type.
768 * --thorpej@netbsd.org, November 30, 1999
772 * XDR 64-bit integers
779 switch (xdrs->x_op) { in xdr_int64_t()
803 * XDR unsigned 64-bit integers
810 switch (xdrs->x_op) { in xdr_u_int64_t()
833 * XDR unsigned 64-bit integers
840 switch (xdrs->x_op) { in xdr_uint64_t()
871 * Don't bother open-coding this; it's a fair amount of code. Just in xdr_hyper()
886 * Don't bother open-coding this; it's a fair amount of code. Just in xdr_u_hyper()
901 * Don't bother open-coding this; it's a fair amount of code. Just in xdr_longlong_t()
916 * Don't bother open-coding this; it's a fair amount of code. Just in xdr_u_longlong_t()