2012-10-01 Patsy Franklin <pfrankli@redhat.com>

Honza Horak <hhorak@redhat.com>

        * nis/yp_xdr.c (xdr_domainname): Use YPMAXDOMAIN as maxsize.
        (xdr_mapname): Use YPMAXMAP as maxsize.
        (xdr_peername): Use YPMAXPEER as maxsize.
        (xdr_keydat): Use YPAXRECORD as maxsize.
        (xdr_valdat): Use YPMAXRECORD as maxsize.
This commit is contained in:
Jeff Law 2012-10-01 15:32:39 -06:00
parent 497a03d6f1
commit 4d57bf6393
2 changed files with 14 additions and 5 deletions

View File

@ -1,3 +1,12 @@
2012-10-01 Patsy Franklin <pfrankli@redhat.com>
Honza Horak <hhorak@redhat.com>
* nis/yp_xdr.c (xdr_domainname): Use YPMAXDOMAIN as maxsize.
(xdr_mapname): Use YPMAXMAP as maxsize.
(xdr_peername): Use YPMAXPEER as maxsize.
(xdr_keydat): Use YPAXRECORD as maxsize.
(xdr_valdat): Use YPMAXRECORD as maxsize.
2012-10-01 Roland McGrath <roland@hack.frob.com> 2012-10-01 Roland McGrath <roland@hack.frob.com>
* io/openat.c [!__ASSUME_ATFCTS] (__have_atfcts): New global variable. * io/openat.c [!__ASSUME_ATFCTS] (__have_atfcts): New global variable.

View File

@ -49,21 +49,21 @@ libnsl_hidden_def (xdr_ypxfrstat)
bool_t bool_t
xdr_domainname (XDR *xdrs, domainname *objp) xdr_domainname (XDR *xdrs, domainname *objp)
{ {
return xdr_string (xdrs, objp, ~0); return xdr_string (xdrs, objp, YPMAXDOMAIN);
} }
libnsl_hidden_def (xdr_domainname) libnsl_hidden_def (xdr_domainname)
bool_t bool_t
xdr_mapname (XDR *xdrs, mapname *objp) xdr_mapname (XDR *xdrs, mapname *objp)
{ {
return xdr_string (xdrs, objp, ~0); return xdr_string (xdrs, objp, YPMAXMAP);
} }
libnsl_hidden_def (xdr_mapname) libnsl_hidden_def (xdr_mapname)
bool_t bool_t
xdr_peername (XDR *xdrs, peername *objp) xdr_peername (XDR *xdrs, peername *objp)
{ {
return xdr_string (xdrs, objp, ~0); return xdr_string (xdrs, objp, YPMAXPEER);
} }
libnsl_hidden_def (xdr_peername) libnsl_hidden_def (xdr_peername)
@ -71,7 +71,7 @@ bool_t
xdr_keydat (XDR *xdrs, keydat *objp) xdr_keydat (XDR *xdrs, keydat *objp)
{ {
return xdr_bytes (xdrs, (char **) &objp->keydat_val, return xdr_bytes (xdrs, (char **) &objp->keydat_val,
(u_int *) &objp->keydat_len, ~0); (u_int *) &objp->keydat_len, YPMAXRECORD);
} }
libnsl_hidden_def (xdr_keydat) libnsl_hidden_def (xdr_keydat)
@ -79,7 +79,7 @@ bool_t
xdr_valdat (XDR *xdrs, valdat *objp) xdr_valdat (XDR *xdrs, valdat *objp)
{ {
return xdr_bytes (xdrs, (char **) &objp->valdat_val, return xdr_bytes (xdrs, (char **) &objp->valdat_val,
(u_int *) &objp->valdat_len, ~0); (u_int *) &objp->valdat_len, YPMAXRECORD);
} }
libnsl_hidden_def (xdr_valdat) libnsl_hidden_def (xdr_valdat)