svn commit: r199787 - head/lib/libc/rpc

Garrett Wollman wollman at FreeBSD.org
Wed Nov 25 04:53:38 UTC 2009


Author: wollman
Date: Wed Nov 25 04:53:38 2009
New Revision: 199787
URL: http://svn.freebsd.org/changeset/base/199787

Log:
  Style: use structure assignment rather than memcpy() to copy a
  structure.

Modified:
  head/lib/libc/rpc/getrpcent.c

Modified: head/lib/libc/rpc/getrpcent.c
==============================================================================
--- head/lib/libc/rpc/getrpcent.c	Wed Nov 25 04:52:12 2009	(r199786)
+++ head/lib/libc/rpc/getrpcent.c	Wed Nov 25 04:53:38 2009	(r199787)
@@ -698,7 +698,7 @@ rpc_marshal_func(char *buffer, size_t *b
 		return (NS_RETURN);
 	}
 
-	memcpy(&new_rpc, rpc, sizeof(struct rpcent));
+	new_rpc = *rpc;
 
 	*buffer_size = desired_size;
 	memset(buffer, 0, desired_size);


More information about the svn-src-head mailing list