From 51939b62b8ac0aa24ff9999d66319772d081829a Mon Sep 17 00:00:00 2001 From: Doug Nazar Date: Mon, 27 Nov 2023 09:01:38 -0500 Subject: [PATCH] audioringbuffer: Don't try to map MONO channel Avoids critical message: gstaudioringbuffer.c: line 2155 (gst_audio_ring_buffer_set_channel_positions): should not be reached Part-of: --- .../gst-plugins-base/gst-libs/gst/audio/gstaudioringbuffer.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/subprojects/gst-plugins-base/gst-libs/gst/audio/gstaudioringbuffer.c b/subprojects/gst-plugins-base/gst-libs/gst/audio/gstaudioringbuffer.c index d718b85d44..dc38ee6d16 100644 --- a/subprojects/gst-plugins-base/gst-libs/gst/audio/gstaudioringbuffer.c +++ b/subprojects/gst-plugins-base/gst-libs/gst/audio/gstaudioringbuffer.c @@ -2086,6 +2086,11 @@ gst_audio_ring_buffer_set_channel_positions (GstAudioRingBuffer * buf, if (memcmp (position, to, channels * sizeof (to[0])) == 0) return; + if (channels == 1) { + GST_LOG_OBJECT (buf, "single channel, no need to reorder"); + return; + } + if (position_less_channels (position, channels)) { GST_LOG_OBJECT (buf, "position-less channels, no need to reorder"); return;