From 11dadd547c08a3480ea153482e99c6ae70b73415 Mon Sep 17 00:00:00 2001 From: wdenk Date: Fri, 27 Feb 2004 00:07:27 +0000 Subject: * Patch by Steven Scholz, 25 Feb 2004: - Timeouts in FPGA code should be based on CFG_HZ - Minor cleanup in code for Altera FPGA ACEX1K * Patch by Steven Scholz, 25 Feb 2004: Changed "Directory Hierarchy" section in README * Patch by Masami Komiya, 25 Feb 2004: Reduce copy count in nfs_read_reply() of NFS code --- net/nfs.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'net/nfs.c') diff --git a/net/nfs.c b/net/nfs.c index 069f072574..2363d61a33 100644 --- a/net/nfs.c +++ b/net/nfs.c @@ -542,7 +542,7 @@ nfs_read_reply (uchar *pkt, unsigned len) printf ("%s\n", __FUNCTION__); #endif - memcpy ((uchar *)&rpc_pkt, pkt, len); + memcpy ((uchar *)&rpc_pkt, pkt, sizeof(rpc_pkt.u.reply)); if (rpc_pkt.u.reply.rstatus || rpc_pkt.u.reply.verifier || @@ -565,7 +565,7 @@ nfs_read_reply (uchar *pkt, unsigned len) } rlen = ntohl(rpc_pkt.u.reply.data[18]); - store_block ((uchar *)&(rpc_pkt.u.reply.data[19]), nfs_offset, rlen); + store_block ((uchar *)pkt+sizeof(rpc_pkt.u.reply), nfs_offset, rlen); return rlen; } -- cgit v1.2.1