This is an automated email from the git hooks/post-receive script.

Git pushed a commit to branch master
in repository ffmpeg.

commit 34bc95ddfcee719346b4fe6dd08f5b0d0f6874f4
Author:     Andreas Rheinhardt <[email protected]>
AuthorDate: Fri Dec 19 08:24:43 2025 +0100
Commit:     Andreas Rheinhardt <[email protected]>
CommitDate: Fri Dec 19 21:45:21 2025 +0100

    avformat/whip: Check number of audio/video streams generically
    
    Reviewed-by: Steven Liu <[email protected]>
    Reviewed-by: Jack Lau <[email protected]>
    Signed-off-by: Andreas Rheinhardt <[email protected]>
---
 libavformat/whip.c | 10 +---------
 1 file changed, 1 insertion(+), 9 deletions(-)

diff --git a/libavformat/whip.c b/libavformat/whip.c
index 7fbe8790ab..1093b8583e 100644
--- a/libavformat/whip.c
+++ b/libavformat/whip.c
@@ -523,10 +523,6 @@ static int parse_codec(AVFormatContext *s)
         AVCodecParameters *par = s->streams[i]->codecpar;
         switch (par->codec_type) {
         case AVMEDIA_TYPE_VIDEO:
-            if (whip->video_par) {
-                av_log(whip, AV_LOG_ERROR, "Only one video stream is supported 
by RTC\n");
-                return AVERROR(EINVAL);
-            }
             whip->video_par = par;
 
             if (par->video_delay > 0) {
@@ -549,10 +545,6 @@ static int parse_codec(AVFormatContext *s)
             }
             break;
         case AVMEDIA_TYPE_AUDIO:
-            if (whip->audio_par) {
-                av_log(whip, AV_LOG_ERROR, "Only one audio stream is supported 
by RTC\n");
-                return AVERROR(EINVAL);
-            }
             whip->audio_par = par;
 
             if (par->ch_layout.nb_channels != 2) {
@@ -2040,7 +2032,7 @@ const FFOutputFormat ff_whip_muxer = {
     .p.subtitle_codec   = AV_CODEC_ID_NONE,
     .p.flags            = AVFMT_GLOBALHEADER | AVFMT_NOFILE | 
AVFMT_EXPERIMENTAL,
     .p.priv_class       = &whip_muxer_class,
-    .flags_internal     = FF_OFMT_FLAG_ONLY_DEFAULT_CODECS,
+    .flags_internal     = FF_OFMT_FLAG_ONLY_DEFAULT_CODECS | 
FF_OFMT_FLAG_MAX_ONE_OF_EACH,
     .priv_data_size     = sizeof(WHIPContext),
     .init               = whip_init,
     .write_packet       = whip_write_packet,

_______________________________________________
ffmpeg-cvslog mailing list -- [email protected]
To unsubscribe send an email to [email protected]

Reply via email to