| Summary: | Sound issues with SDL 2.0.6 | ||
|---|---|---|---|
| Product: | SDL | Reporter: | Simon Howard <fraggle+libsdl> |
| Component: | audio | Assignee: | Ryan C. Gordon <icculus> |
| Status: | RESOLVED FIXED | QA Contact: | Sam Lantinga <slouken> |
| Severity: | blocker | ||
| Priority: | P2 | CC: | devnexen, ewasylishen, jajdorkster, janisozaur+libsdl, sezeroz |
| Version: | 2.0.6 | ||
| Hardware: | x86 | ||
| OS: | Other | ||
|
Description
Simon Howard
2017-10-02 21:12:16 UTC
Ryan, can you look at this ASAP? Hi here the person who posted the error on GitHub. It seems very likely it is, got a segmentation fault for similar reason, the 3849 leads me to think I was not extremely far from the truth. On Arch Linux, unlike Debian based distros, there is no separated packages with debug symbols but I started to have a look at the code and it seems there is quite a change between 2.0.5 and 2.0.6 ... could this be, somewhat, related to it ? http://hg.libsdl.org/SDL/file/8df7a59b5528/src/audio/SDL_audiocvt.c#l807 bug #3848 and bug #3849 do cover both issues spotted in 2.0.6 release. I think this report can be considered a duplicate of those two. I think I've also encountered this bug. I've posted a trace here: https://github.com/clintbellanger/flare-engine/issues/1516#issuecomment-335667432 It appears that this bug happens when resampling sounds from high -> low frequencies. In our case, we're going from 44100Hz to 22050Hz. Using a higher frequency for Mix_OpenAudio() results in no crash. Can you check to see if this is fixed in the latest snapshot? http://www.libsdl.org/tmp/SDL-2.0.zip Thanks! The issue I was having appears to have been fixed in that snapshot. Nice work! I think this is fixed along with the other mentioned reports, so I'm resolving this bug. --ryan. Multiple reports from Chocolate Doom users are that this is still not fixed. <https://github.com/chocolate-doom/chocolate-doom/issues/945> It looks like a bug in Chocolate Doom (buffer passed to SDL_ConvertAudio is smaller than the required len*len_mult), see my comment on https://github.com/chocolate-doom/chocolate-doom/issues/945 The question is, since the change from SDL_memcpy to SDL_memmove did not fully fix it (I think personally it s a good change to keep), and if the code consumers really need to allocate more memory than with versions <= 2.0.6, assuming it is intended and not a edgy bug, would it be relevant to mention it in changelogs, relevant C header file ... ? because not obvious unless you read the source code to realise it has been rewritten :-) #11 is correct. It looks like this was indeed a bug in Chocolate Doom, albeit one that appears to only have been exposed due to the recent audio changes. A fix has now been merged in Chocolate Doom. |