Explorar el Código

Fixed SDL_ConvertMonoToStereo_SSE reading out of bounds

Brick hace 2 años
padre
commit
1ee2832326
Se han modificado 1 ficheros con 2 adiciones y 2 borrados
  1. 2 2
      src/audio/SDL_audiocvt.c

+ 2 - 2
src/audio/SDL_audiocvt.c

@@ -189,8 +189,8 @@ static void SDL_TARGETING("sse") SDL_ConvertMonoToStereo_SSE(float *dst, const f
     int i = num_frames;
 
     /* convert backwards, since output is growing in-place. */
-    src += (num_frames-1) * 1;
-    dst += (num_frames-1) * 2;
+    src += (num_frames-4) * 1;
+    dst += (num_frames-4) * 2;
 
     LOG_DEBUG_AUDIO_CONVERT("mono", "stereo (using SSE)");