[MPlayer-dev-eng] [PATCH] Use memmove when source and destination can overlap

Reimar Döffinger Reimar.Doeffinger at gmx.de
Wed Mar 9 22:11:18 CET 2011


On Wed, Mar 09, 2011 at 07:53:15PM +0100, Tobias Diedrich wrote:
> Use memmove when source and destination can overlap.

Seems ok.

> glibc behaviour recently changed:
> http://lwn.net/Articles/414467/

Broken code is broken code, even if it worked with glibc before.

> Maybe we should an assert to fast_memcpy when compiled with debugging enabled?

valgrind should catch the cases where it is actually an error.
If you replace fast_memcpy by memcpy valgrind would catch them all.
So I don't really feel like it has much of an advantage to do that.


More information about the MPlayer-dev-eng mailing list