public inbox for libc-hacker@sourceware.org
 help / color / mirror / Atom feed
* [PATCH] map_v4v6_address
@ 2006-11-21 12:18 Jakub Jelinek
  0 siblings, 0 replies; only message in thread
From: Jakub Jelinek @ 2006-11-21 12:18 UTC (permalink / raw)
  To: Ulrich Drepper; +Cc: Glibc hackers

Hi!

src is const char * (and furthermore not necessarily equal to dst).
I wonder if you don't want to copy to dst + 12 (or p + 12, which is
the same thing) instead.

2006-10-21  Jakub Jelinek  <jakub@redhat.com>

	* resolv/mapv4v6addr.h (map_v4v6_address): Fix last change.

--- libc/resolv/mapv4v6addr.h.jj	2006-11-21 13:08:02.000000000 +0100
+++ libc/resolv/mapv4v6addr.h	2006-11-21 13:10:02.000000000 +0100
@@ -59,7 +59,7 @@ map_v4v6_address (const char *src, char 
   int i;
 
   /* Move the IPv4 part to the right position.  */
-  memcpy (src + 12, src, INADDRSZ);
+  memcpy (dst + 12, src, INADDRSZ);
 
   /* Mark this ipv6 addr as a mapped ipv4. */
   for (i = 0; i < 10; i++)

	Jakub

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2006-11-21 12:18 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2006-11-21 12:18 [PATCH] map_v4v6_address Jakub Jelinek

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).