From 903ff6414eecc42b2b36c35d67e9b78fe7cb9d7a Mon Sep 17 00:00:00 2001 From: "Ryan C. Gordon" Date: Tue, 10 Oct 2017 22:31:02 -0400 Subject: [PATCH] audio: SDL_ResampleCVT() should use memmove instead of memcpy. This copy can overlap. Fixes Bugzilla #3849. --- src/audio/SDL_audiocvt.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/audio/SDL_audiocvt.c b/src/audio/SDL_audiocvt.c index 073e7ee95..c44485c17 100644 --- a/src/audio/SDL_audiocvt.c +++ b/src/audio/SDL_audiocvt.c @@ -732,7 +732,7 @@ SDL_ResampleCVT(SDL_AudioCVT *cvt, const int chans, const SDL_AudioFormat format SDL_free(padding); - SDL_memcpy(cvt->buf, dst, cvt->len_cvt); /* !!! FIXME: remove this if we can get the resampler to work in-place again. */ + SDL_memmove(cvt->buf, dst, cvt->len_cvt); /* !!! FIXME: remove this if we can get the resampler to work in-place again. */ if (cvt->filters[++cvt->filter_index]) { cvt->filters[cvt->filter_index](cvt, format);