Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/netbsd-6-0]: src/lib/libc/rpc Pull up following revision(s) (requested b...



details:   https://anonhg.NetBSD.org/src/rev/486a8738ffee
branches:  netbsd-6-0
changeset: 774788:486a8738ffee
user:      riz <riz%NetBSD.org@localhost>
date:      Sun Mar 31 20:26:59 2013 +0000

description:
Pull up following revision(s) (requested by christos in ticket #854):
        lib/libc/rpc/clnt_vc.c: revision 1.19
PR/13082: Thorsten Brehm: Fix wrong memcpy that caused possible memory
corruption. XXX: pullup to 6.

diffstat:

 lib/libc/rpc/clnt_vc.c |  8 ++++----
 1 files changed, 4 insertions(+), 4 deletions(-)

diffs (29 lines):

diff -r 9e750644a429 -r 486a8738ffee lib/libc/rpc/clnt_vc.c
--- a/lib/libc/rpc/clnt_vc.c    Sun Mar 31 20:21:15 2013 +0000
+++ b/lib/libc/rpc/clnt_vc.c    Sun Mar 31 20:26:59 2013 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: clnt_vc.c,v 1.17 2010/12/08 02:06:38 joerg Exp $       */
+/*     $NetBSD: clnt_vc.c,v 1.17.12.1 2013/03/31 20:26:59 riz Exp $    */
 
 /*
  * Sun RPC is a product of Sun Microsystems, Inc. and is provided for
@@ -36,7 +36,7 @@
 static char *sccsid = "@(#)clnt_tcp.c  2.2 88/08/01 4.0 RPCSRC";
 static char sccsid[] = "@(#)clnt_vc.c 1.19 89/03/16 Copyr 1988 Sun Micro";
 #else
-__RCSID("$NetBSD: clnt_vc.c,v 1.17 2010/12/08 02:06:38 joerg Exp $");
+__RCSID("$NetBSD: clnt_vc.c,v 1.17.12.1 2013/03/31 20:26:59 riz Exp $");
 #endif
 #endif
  
@@ -262,8 +262,8 @@
        ct->ct_addr.buf = malloc((size_t)raddr->maxlen);
        if (ct->ct_addr.buf == NULL)
                goto fooy;
-       memcpy(ct->ct_addr.buf, &raddr->buf, (size_t)raddr->len);
-       ct->ct_addr.len = raddr->maxlen;
+       memcpy(ct->ct_addr.buf, raddr->buf, (size_t)raddr->len);
+       ct->ct_addr.len = raddr->len;
        ct->ct_addr.maxlen = raddr->maxlen;
 
        /*



Home | Main Index | Thread Index | Old Index