This is the mail archive of the glibc-bugs@sourceware.org mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug libc/12518] memcpy acts randomly (and differently) with overlapping areas


http://sourceware.org/bugzilla/show_bug.cgi?id=12518

--- Comment #4 from Ulrich Drepper <drepper.fsp at gmail dot com> 2011-02-25 09:59:18 UTC ---
The existence of code written by people who should never have been allowed to
touch a keyboard cannot be allowed to prevent a correct implementation.  If
there is a large bod of code out there we can work around the issue for that.

We can have the existing memcpy@GLIBC_2.2.5 implementation work around the
issue by avoiding the backward copying code.  A new memcpy@GLIBC_2.14 could use
the code currently in use.

Whether the current, new memcpy is only slightly faster than one mimicking
memmove is really not that important.  There are going to be more and different
implementations in the future and they shouldn't be prevented from being used
because of buggy programs.  We should be happy to have this code here and now.

With this proposed implementation old code remains in working order until those
lousy programmers use a newer platform and then they will experience the
problems themselves and will fix them before releasing their code.

I'm happy to entertain a patch to this effect.

-- 
Configure bugmail: http://sourceware.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]