From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from ffbox0-bg.ffmpeg.org (ffbox0-bg.ffmpeg.org [79.124.17.100]) by master.gitmailbox.com (Postfix) with ESMTPS id E5A424FB15 for ; Thu, 26 Jun 2025 19:47:50 +0000 (UTC) Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.ffmpeg.org (Postfix) with ESMTP id 776C868E4E2; Thu, 26 Jun 2025 22:47:46 +0300 (EEST) Received: from mail-ej1-f50.google.com (mail-ej1-f50.google.com [209.85.218.50]) by ffbox0-bg.ffmpeg.org (Postfix) with ESMTPS id D2EBD68E2D3 for ; Thu, 26 Jun 2025 22:47:39 +0300 (EEST) Received: by mail-ej1-f50.google.com with SMTP id a640c23a62f3a-ae0a420431bso278587866b.2 for ; Thu, 26 Jun 2025 12:47:39 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1750967259; x=1751572059; darn=ffmpeg.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=hq22ZlIUChIGfEDs6Tvj8LI0B1lI2Q10BLrJpNxMvSc=; b=hVkmBJnQYvpnuMP30RRd+6YCoqoj8j2KrMOK+w0OXdym9o3cHzO34AuhgJFUiDIH64 gYx8Zh2UXtNrveMoUso7sOGSIqUlrdPNHboEH/f02niAX7ADBb31yG4eh18wmmiqSwFU rzwQStLMPv0JbuOi25vpTnba2vPh2yDCh7aPdAXAA4Il6J1vPnOSwB8Qt4t39l/grezx ozhQ8kiJjjRLCZ5WPnwqXogCjmq5VQUgTNR1o6yB8FK3Q0u9whXtJ+G0o81Z15goQZtS dBwy9Edt6FA+pFQPriblrRB/KU8+95q4Vm3/m8fF2zuZ432qTl5rqezOlqkDBATP4iXr u2Gw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1750967259; x=1751572059; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=hq22ZlIUChIGfEDs6Tvj8LI0B1lI2Q10BLrJpNxMvSc=; b=JToyuStMd+Ufmyv3S5RnpYfHE/AmNnL4uMBbgS1UKbFkC4SfcbraeuZ1s41KRE0SEb XKkLxlTS//dRXurEVKEAKdM4Vu+tqbCpx5H7kAsO+nKBmqB8LPbM8Ab/JRCaVDOq+m+A n8bPiNfBZg0wOU7mgMJ2YfRBP7jlSyyENVw3dcWaIuiU4CoZ+jX80QL5A9r1zK0AUCOe 3QLUFBb+f1pj75/NZJUlQpzSqYTCXLRPDS3Gj0Ag+VWunWqxQD0ZOs8FDFncBkEzpl+f Lko/JKboQKEorxelpLvs06cKLASN3w3x1y3rr/63uhCAwjKDHHjN0xld/8wFWKU0PgDk JjlQ== X-Gm-Message-State: AOJu0Yyy0+FnI+NbEDE2i2zT5lwfFJoku66CsozxT2WqW+GqaxGHdz/H AjVjwdI1poCqp6/TqyBC0gW9hmnpFc7Qhhr8j50mFEJwIQhGTwNjeQZkrndV+A== X-Gm-Gg: ASbGncuQtYpNGVawOLsEid2nwhLcCGas0RzfPJLU23yo7dMxMJ/0Jux9v4phOMCSn5C 9g9bhOHDbXUTlmJg2f9kJS/hfuEk5dhaDP6F5+degYZ72vxXoS7qeHNofvXCNgdMtDRuS7BYp2x 1qSiujRfeBLPRkb4xuS5JnA1asPKBol0WJdPeNvVi7S10ZLWt1kk/d6hIjPtQAtxhnLAzaUSejs tq3ggVYthO0Xnq56uSNXeEs7W70IlD5LSt8PueZsLIPlctcNQLb7oDIJeFyfcXmKeb/XHl35VZI HuRbyijG52I+USSrViXL9mcDmc19oMSECR371gnnvx9frDdEnOm4Wfd4foJRwK/4a+cxfV/Qbtt TC8s5H9NZ+p+owPtyXHNQ5mv5ii/bbURwvpaEUll1Xm+K/IFELXJQPPf+SfeNKIfX2Ib1HT7Dkq w= X-Google-Smtp-Source: AGHT+IH3nqpMftJWC519QDLgSm9g4tggPbtADyt+bRiUwdIwlb5Fzbq0A6dV8KDd+MgeDtbnD0A60g== X-Received: by 2002:a17:907:c1c:b0:ade:3eb6:3c6 with SMTP id a640c23a62f3a-ae34fd3aeb9mr31380166b.15.1750967258847; Thu, 26 Jun 2025 12:47:38 -0700 (PDT) Received: from [192.168.178.57] (p20030102370045007d7f230e46ac5795.dip0.t-ipconnect.de. [2003:102:3700:4500:7d7f:230e:46ac:5795]) by smtp.gmail.com with ESMTPSA id a640c23a62f3a-ae202026f52sm45889666b.9.2025.06.26.12.47.37 for (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128); Thu, 26 Jun 2025 12:47:38 -0700 (PDT) From: Marvin Scholz To: FFmpeg development discussions and patches Date: Thu, 26 Jun 2025 21:47:37 +0200 X-Mailer: MailMate (2.0r6222) Message-ID: <2106E09E-3926-4575-9D7E-B91F2926EF21@gmail.com> In-Reply-To: <20250606030206.67340-1-lq@chinaffmpeg.org> References: <20250606030206.67340-1-lq@chinaffmpeg.org> MIME-Version: 1.0 Subject: Re: [FFmpeg-devel] [PATCH 1/2] avformat/whip: Remove unnecessary pkt checks X-BeenThere: ffmpeg-devel@ffmpeg.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: FFmpeg development discussions and patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: FFmpeg development discussions and patches Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" Archived-At: List-Archive: List-Post: On 6 Jun 2025, at 5:02, Steven Liu wrote: > h264_annexb_insert_sps_pps (called after write_packet) > reorganizes PPS, SPS, and IDR packets in H.264 streams. > Since write_packet already validates pkt, > redundant null checks in h264_annexb_insert_sps_pps can be removed. > > Signed-off-by: Steven Liu > --- > libavformat/whip.c | 2 -- > 1 file changed, 2 deletions(-) > > diff --git a/libavformat/whip.c b/libavformat/whip.c > index 0671e23635..ce06a66bc4 100644 > --- a/libavformat/whip.c > +++ b/libavformat/whip.c > @@ -1660,8 +1660,6 @@ static int h264_annexb_insert_sps_pps(AVFormatContext *s, AVPacket *pkt) > uint8_t unit_type, sps_seen = 0, pps_seen = 0, idr_seen = 0, *out; > const uint8_t *buf, *buf_end, *r1; > > - if (!pkt || !pkt->data || pkt->size <= 0) > - return ret; > if (!par || !par->extradata || par->extradata_size <= 0) > return ret; > > -- > 2.39.3 (Apple Git-146) LGTM, pushed as 87808e38a86ad3980115f97774ab53e781178767. Thanks. > > _______________________________________________ > ffmpeg-devel mailing list > ffmpeg-devel@ffmpeg.org > https://ffmpeg.org/mailman/listinfo/ffmpeg-devel > > To unsubscribe, visit link above, or email > ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe". _______________________________________________ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-devel To unsubscribe, visit link above, or email ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".