This commit is contained in:
pf 2023-03-27 22:50:27 +01:00
parent c0c6b0d601
commit bf6ac2e318

View File

@ -516,7 +516,7 @@ namespace dlib
inline std::string get_channel_layout_str(const AVChannelLayout& ch_layout)
{
std::string str(32, '\0');
const int ret = av_channel_layout_describe(&ch_layout, str.data(), str.size());
const int ret = av_channel_layout_describe(&ch_layout, &str[0], str.size());
if (ret > 0)
str.resize(ret);
else