[FFmpeg-devel] [PATCH 01/10] zlib decoder

Måns Rullgård mans
Mon Jul 16 09:24:45 CEST 2007

Vadim Lebedev <vadim at mbdsys.com> writes:

>>>>+static void
>>>>+copy_bytes(uint8_t *dst, uint8_t *src, unsigned int len)
>>>>+    while (len--)
>>>>+        *dst++ = *src++;
>>>i think we have such a copy routine somewhere already, but i dont remember
>>Reimar said it looked familiar too.  Wherever it is, it's not in a
>>central location.  Where would be the appropriate place for a function
>>like this?
> Why don't you simply use memcpy in this case?

Because memcpy() has undefined behaviour if the source and destination

M?ns Rullg?rd
mans at mansr.com

More information about the ffmpeg-devel mailing list