diff options
author | Ricardo M. Correia <[email protected]> | 2009-03-11 05:39:03 +0000 |
---|---|---|
committer | Brian Behlendorf <[email protected]> | 2009-03-11 16:27:35 -0700 |
commit | 6c33eb816268ef3fef9bb8ca9079bb46aad26605 (patch) | |
tree | 6a2c6d3160aeb648531761dc56b9a2af04f80106 | |
parent | f48b61938a7efc427946418e987ce751ca6160c7 (diff) |
Minor bug fix in XDR code introduced in last minute change before landing.
1) Removed xdr_bytesrec typedef which has no consumers. If we re-add
it should also probably be xdr_bytesrec_t.
-rw-r--r-- | include/rpc/xdr.h | 2 | ||||
-rw-r--r-- | module/spl/spl-xdr.c | 4 |
2 files changed, 2 insertions, 4 deletions
diff --git a/include/rpc/xdr.h b/include/rpc/xdr.h index 5b8165460..43919ca25 100644 --- a/include/rpc/xdr.h +++ b/include/rpc/xdr.h @@ -68,8 +68,6 @@ struct xdr_bytesrec { size_t xc_num_avail; }; -typedef struct xdr_bytesrec xdr_bytesrec; - /* * XDR functions. */ diff --git a/module/spl/spl-xdr.c b/module/spl/spl-xdr.c index feaa59e4f..16e42c336 100644 --- a/module/spl/spl-xdr.c +++ b/module/spl/spl-xdr.c @@ -186,7 +186,7 @@ xdrmem_enc_bytes(XDR *xdrs, caddr_t cp, const uint_t cnt) if (xdrs->x_addr > xdrs->x_addr_end) return FALSE; - if (xdrs->x_addr_end - xdrs->x_addr > size) + if (xdrs->x_addr_end - xdrs->x_addr < size) return FALSE; memcpy(xdrs->x_addr, cp, cnt); @@ -215,7 +215,7 @@ xdrmem_dec_bytes(XDR *xdrs, caddr_t cp, const uint_t cnt) if (xdrs->x_addr > xdrs->x_addr_end) return FALSE; - if (xdrs->x_addr_end - xdrs->x_addr > size) + if (xdrs->x_addr_end - xdrs->x_addr < size) return FALSE; memcpy(cp, xdrs->x_addr, cnt); |