Closed marler8997 closed 6 months ago
Thanks for the report and the repro. I've finally got around to checking this, but unfortunately I've been unable to replicate it on both the dev branch and the master branch. I tried with both MSVC and Clang and neither are crashing. What version of miniaudio are you using? If not the latest, are you able to try the master or dev branch?
Ah yes looks like it's passing on master now. I've bisected the fix to this commit: f6e5cf10ae10494cf7215a2b2262092e8247dd7f
Closing
Initializing a channel converter (also applies to a general data converter) with 2 input channels and more than 2 output channels results in a NULL dereference. I've provided a sample program to reproduce below. The issue occurs in
ma_channel_converter_init_preallocated
inside thema_channel_mix_mode_rectangular
mixing mode switch case. The expressionpConverter->pChannelMapIn
isNULL
but the initializer attempts to index it with an input channel index.