Skip to content

Commit

Permalink
backport fix for bug 2670 - Possible memory overflow in Mix_LoadWAV_RW
Browse files Browse the repository at this point in the history
  • Loading branch information
sezero committed Sep 3, 2019
1 parent 44e75df commit e9ab6aa
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion mixer.c
Expand Up @@ -650,7 +650,7 @@ Mix_Chunk *Mix_LoadWAV_RW(SDL_RWops *src, int freesrc)
SDL_free(chunk);
return(NULL);
}
memcpy(wavecvt.buf, chunk->abuf, chunk->alen);
memcpy(wavecvt.buf, chunk->abuf, wavecvt.len);
SDL_free(chunk->abuf);

/* Run the audio converter */
Expand Down

0 comments on commit e9ab6aa

Please sign in to comment.