From patchwork Sat Mar 23 02:03:52 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andreas Rheinhardt X-Patchwork-Id: 47349 Delivered-To: ffmpegpatchwork2@gmail.com Received: by 2002:a05:6a21:1014:b0:1a3:ac71:9534 with SMTP id nk20csp285030pzb; Fri, 22 Mar 2024 19:04:31 -0700 (PDT) X-Forwarded-Encrypted: i=2; AJvYcCUjutXMLhl4/NB1hn6BFJTPmIsEeHMdbtkSHrfCPFy//GHkM3U2Y2rlXuVVUkvPYxN9qGsQoHYKidL1T0CpNvw2CBofhYF3r3T/rw== X-Google-Smtp-Source: AGHT+IGqwz8DeyT6li6Clr9FfNY4einGXQix6wGdSNAkkx4JnFerRaYPpLFCpwbfjkbU2Rq1DjiF X-Received: by 2002:adf:f251:0:b0:341:bf35:5082 with SMTP id b17-20020adff251000000b00341bf355082mr627825wrp.2.1711159471429; Fri, 22 Mar 2024 19:04:31 -0700 (PDT) Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org. [79.124.17.100]) by mx.google.com with ESMTP id m10-20020a1709060d8a00b00a4663b17910si358594eji.739.2024.03.22.19.04.30; Fri, 22 Mar 2024 19:04:31 -0700 (PDT) Received-SPF: pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) client-ip=79.124.17.100; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@outlook.com header.s=selector1 header.b=n0oSNnqi; arc=fail (body hash mismatch); spf=pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) smtp.mailfrom=ffmpeg-devel-bounces@ffmpeg.org; dmarc=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=outlook.com Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id 0FD4C68D4E0; Sat, 23 Mar 2024 04:04:27 +0200 (EET) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from EUR03-AM7-obe.outbound.protection.outlook.com (mail-am7eur03olkn2070.outbound.protection.outlook.com [40.92.59.70]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id 4E7BF68D4E0 for ; Sat, 23 Mar 2024 04:04:20 +0200 (EET) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=lNSqDXqnO9flf0Fgs91+s/QRXStxmfIgzh5Xapu0rrHqf5ITkwc3kjmpZUvCQQvovVatTJHtDzB4ap7Y4CtpLv/RJIgRo6a1S06oMAow4c7lY0exZsMM/NjiYoJMPOh0zbp6LTGUBIdCxM9adkkLu3dOyuObfGABuSSZJub/uiy/WUjz/8umYEiqfoCh/aocHRdmfcQ1uBP+v2zIct+ghI8Wb8Zr0pXiHepr8/Xbr10gd5e+C3KNyjdppR54HMSJmhzDvXzbcUvD0mXkMFaXGe0xBbZ8zqZOsr7QNeQIxQqfNcsnRwCh4Pw7N3ObmEQRWAV5eVDjeikJy5uwb1D2fw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=0TrmIDLBGKFIw13KqjfgLBvZMN6bd6FH1+22JeluXs8=; b=azohwQktA4YDQWhwHmxKhVq/bkfWGF3ChCwqUTiPOp1GYglgk9XI33pWBN6eX/Oyf/k/orhutjKekgfQUia2DxWOAcflbGsZ4j0Jb6b30xF87u4NCt/XcnFVFxdAOi/cQGs5fRbWTlvAUV27zhnIp0iXCiKZ06O0pk3nmQB+mbjav4V8ckbWp3sCDwoQelgKSbK6r5H/wvCohyZnnHp0zZLRG2STalsxHBxESf7IgTsCKe3kPTkZmpGRt02BRydP/GwpRKPNwQ5V6TGf6U/a+OAj/eolxiiuPGBQP4QGsF5AdLBS2zag4O3suCLyK1926D/+6MNfIvW9cRN5OzadWA== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=none; dmarc=none; dkim=none; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=outlook.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=0TrmIDLBGKFIw13KqjfgLBvZMN6bd6FH1+22JeluXs8=; b=n0oSNnqivakLXDx3xN4XOEDzeE8P/qMkwxjjX+0oFPTBUM4YPpcPwYMrc4BnRsY5aEFHa6MaIaGTrNvYAj75lIe2sffHB03c0Qh/QK5Avrl5i8Hj69jz0NdUNa7H9Vo5wLjNYqP/CTRSjoJEAtczxYzPjeUpiLy0ZS5xSS86ZIffOgOHXZD/gh/2XstNLsMOXlUXNycgz2aOme3klqiEn0oLczLMUL1ZTxWETk52Ztu70rec5r9GhL4k/WEP+6FtNgOXPykCqVsS6CCfWQKhaecd9HHvXSwj+5fgcAN2rrFE8+phxQ6/QjMMFw+6dfRfkV0k2NCUzOdqOcOeYvxTeQ== Received: from GV1P250MB0737.EURP250.PROD.OUTLOOK.COM (2603:10a6:150:8e::17) by AS8P250MB0219.EURP250.PROD.OUTLOOK.COM (2603:10a6:20b:37a::15) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7409.24; Sat, 23 Mar 2024 02:04:17 +0000 Received: from GV1P250MB0737.EURP250.PROD.OUTLOOK.COM ([fe80::4a3b:cf76:cddc:c68d]) by GV1P250MB0737.EURP250.PROD.OUTLOOK.COM ([fe80::4a3b:cf76:cddc:c68d%4]) with mapi id 15.20.7386.025; Sat, 23 Mar 2024 02:04:17 +0000 From: Andreas Rheinhardt To: ffmpeg-devel@ffmpeg.org Date: Sat, 23 Mar 2024 03:03:52 +0100 Message-ID: X-Mailer: git-send-email 2.40.1 X-TMN: [U4oA6DleOBIEsgxqYTst4x7P0S6SZ/Mz/4rveHLCtpU=] X-ClientProxiedBy: ZR2P278CA0029.CHEP278.PROD.OUTLOOK.COM (2603:10a6:910:46::12) To GV1P250MB0737.EURP250.PROD.OUTLOOK.COM (2603:10a6:150:8e::17) X-Microsoft-Original-Message-ID: <20240323020406.1570907-1-andreas.rheinhardt@outlook.com> MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: GV1P250MB0737:EE_|AS8P250MB0219:EE_ X-MS-Office365-Filtering-Correlation-Id: 87a85269-0aec-4e0a-d0a8-08dc4add8b88 X-MS-Exchange-SLBlob-MailProps: Cq7lScuPrnqkjmXb1vlddM5aSa/Epk3AE9LF9HwLzpUfrPag+m1YVqBzNGpO6DZ/aMNiCBH7HX05Pe3dZEmxOeIJrf/kr8k0KdL0sVNq/JFgcIhQ4LQ4uU7bin7HBaHyeB8ndXam9SgJ2voUp6yQVl1TGYaBCu1/bZLp+qfRIu42XWoi0GRZXK5Us1+CRXA0b0WSMdKWIMB9RPuPvrCjE3tn5K8dATmQ9J3uJRshWIW+Zblq90fNekt/GDNHQE0glFeTVHQ74GZoxPfPr0l9qcgPjohpdX8vgMYWc0gWf2BSsqfjfME3+XTDqDja294c7EhJfgs5ag25byCXDXO0I0asFLh6g/4tB38s0bCMv0wy8vS7A3SwM0Vu0ARpK9PCqKUY3r5ca0Mty7wqDU52Rl5CuqQ/15PQxVk0QxnQVfO3YeYXf5e1bMPNQgxU7vYO9/1vIE1Q65DPctIBh19aUl38StAz8FHLWlzSPYmjqZTAU8dt1ikr98TxyV4sBtc2Mpo9pAd6rqIeBfqTTbgsAZwjJJROgKCfh9RZStuARUqVaFvRIYEefVRBifrrR6JyV668GEvARt60sjOQPpKHXNq1OI7bd8YDB8US7krDH253FTnrjYQ3h3/aJFN5Y6oVgFYZRPA6+DeA9mvsF6s8/D/GN3bYx/Tobmg94A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bB4pdJQRRk41/kA== X-OriginatorOrg: outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: 87a85269-0aec-4e0a-d0a8-08dc4add8b88 X-MS-Exchange-CrossTenant-AuthSource: GV1P250MB0737.EURP250.PROD.OUTLOOK.COM X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 23 Mar 2024 02:04:17.2073 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 84df9e7f-e9f6-40af-b435-aaaaaaaaaaaa X-MS-Exchange-CrossTenant-RMS-PersistedConsumerOrg: 00000000-0000-0000-0000-000000000000 X-MS-Exchange-Transport-CrossTenantHeadersStamped: AS8P250MB0219 Subject: [FFmpeg-devel] [PATCH 01/15] configure: Make hls demuxer select AAC, AC3 and EAC3 demuxers 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 Cc: Andreas Rheinhardt Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" X-TUID: TYQCqtNFg+Zv The code relies on their presence and would presumably crash when retrieving in_fmt->name if an encrypted stream with a codec id without demuxer were encountered. Signed-off-by: Andreas Rheinhardt --- configure | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/configure b/configure index 343edb38ab..90d18e0970 100755 --- a/configure +++ b/configure @@ -3590,7 +3590,7 @@ flac_demuxer_select="flac_parser" flv_muxer_select="aac_adtstoasc_bsf" gxf_muxer_select="pcm_rechunk_bsf" hds_muxer_select="flv_muxer" -hls_demuxer_select="adts_header ac3_parser mov_demuxer mpegts_demuxer" +hls_demuxer_select="aac_demuxer ac3_demuxer adts_header ac3_parser eac3_demuxer mov_demuxer mpegts_demuxer" hls_muxer_select="mov_muxer mpegts_muxer" iamf_demuxer_select="iamfdec" iamf_muxer_select="iamfenc" From patchwork Sat Mar 23 02:06:10 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andreas Rheinhardt X-Patchwork-Id: 47350 Delivered-To: ffmpegpatchwork2@gmail.com Received: by 2002:a05:6a21:1014:b0:1a3:ac71:9534 with SMTP id nk20csp285702pzb; Fri, 22 Mar 2024 19:06:42 -0700 (PDT) X-Forwarded-Encrypted: i=2; AJvYcCWvLpD/fAeHm1TIFTBQpSTCmWVYm8VoRJaUhhO5Qf7e6ojOsQRby0c38bDugB6YDimRvrr7tAJDm/KbIRNrX5DJ37asjTcTenRxTA== X-Google-Smtp-Source: AGHT+IHhQI0GpX1Gay5KIznKKlo+D8z24LJF5rtcmhKQV9G9Vl69W6SB1eX0YO4X/6Zm28hv/M2y X-Received: by 2002:a05:6512:47c:b0:513:edf4:6f20 with SMTP id x28-20020a056512047c00b00513edf46f20mr614442lfd.54.1711159602515; Fri, 22 Mar 2024 19:06:42 -0700 (PDT) Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org. [79.124.17.100]) by mx.google.com with ESMTP id dc19-20020a170906c7d300b00a45b8e1352dsi389930ejb.741.2024.03.22.19.06.42; Fri, 22 Mar 2024 19:06:42 -0700 (PDT) Received-SPF: pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) client-ip=79.124.17.100; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@outlook.com header.s=selector1 header.b=S5vktHa8; arc=fail (body hash mismatch); spf=pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) smtp.mailfrom=ffmpeg-devel-bounces@ffmpeg.org; dmarc=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=outlook.com Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id 400E368D57C; Sat, 23 Mar 2024 04:06:39 +0200 (EET) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from EUR04-DB3-obe.outbound.protection.outlook.com (mail-db3eur04olkn2050.outbound.protection.outlook.com [40.92.74.50]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id CC8FF68D022 for ; Sat, 23 Mar 2024 04:06:32 +0200 (EET) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=C+qSkEyO13kbnk/KQdCo9YQQNYXQt/d16D7nXenWlO83qndcMUgv+9pFqy58EQbPl5EhdvCwvHJ6DRYN9jzcXbvSKV1kr/lxfNFxHdrh/uSmXOjPeYjO8ptV3v85nP9gINdSQVzigecGweHym0vINzjwDzDdhVeHNDMXnuikS2fD46pJV4/fi0hSeSPReTBxxFaibDOhYqvfx+paHBShWF4bjRKAUvIMeR1PhjK6FiNlRoqIjA+xhnKJtMnVHJSaf3QygswXk2qwx9SNZe0+zoLtukSol6PNe6Ui4lten0JwblZ0QeYUAcbSglrdPjSqqF0T46p5pym9602MlvvcCQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=ZFWh1+0K3VyGRoHrA90OxJmIHNv/e+umKpYVZy5g10M=; b=DltSJEAWqH0+5kWEI1/ImCceK0YP+u4au6phjxbyCIsiA/Hi8kVIJENioo8MI0GIcn5EheCf2C93hvna47tG7VNbtN5AutvxYwgRRYxjxCTaXeOJUOm9+pe/oyY/UaImWCujNDZflopNbXrh+OnL/M5QNd8P2kZ2NtdrzgMJLZ/pp1BJhcL+x3EOFmTJQN6OeMJNStNFIX6LuJ1HCsjz9nO3NTjR4piWM52F51N09dMLAxxjdCtLhPLZHM7p8j8WQ7bTlA52zSAadWTfGn07n1mYck+jeA9CybV/Td0rdlesTjRBSjYhAHxqQCApb2VJzV3cPYXKZWANG8ctyE+Qew== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=none; dmarc=none; dkim=none; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=outlook.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=ZFWh1+0K3VyGRoHrA90OxJmIHNv/e+umKpYVZy5g10M=; b=S5vktHa8m4myf2OlYozUgaQbxwDSeoTt+oj9zLMvQP+WQ9/xlrGQrGL3k2LzmumJ0WYR2kxwy9v9xtRcUaeZeglghOKo3SdKwMNaH1LP4woMOTG1qHOKeu5LcXbnpv7vghBer9iO+8Vks4OP6zQms2Q3NG42CZMZddXquRsBETBiqUbOO7BVI23ICW6dPfrCNpSWKSH/gYCf7pmDfGjbWtn/2Gb3RlGr3i18gPTCgbG48RuCDSVOVy6QLyXA2QfBEZjHljoY85mhu+eaAeVYW2jXCqdl2JQcEUZI2uBGRFiZJNLxxvG1325u9nPpDvdPJuhAG+fDq8b1CNxJB4/Qgg== Received: from GV1P250MB0737.EURP250.PROD.OUTLOOK.COM (2603:10a6:150:8e::17) by AM8P250MB0137.EURP250.PROD.OUTLOOK.COM (2603:10a6:20b:320::11) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7409.24; Sat, 23 Mar 2024 02:06:31 +0000 Received: from GV1P250MB0737.EURP250.PROD.OUTLOOK.COM ([fe80::4a3b:cf76:cddc:c68d]) by GV1P250MB0737.EURP250.PROD.OUTLOOK.COM ([fe80::4a3b:cf76:cddc:c68d%4]) with mapi id 15.20.7386.025; Sat, 23 Mar 2024 02:06:31 +0000 From: Andreas Rheinhardt To: ffmpeg-devel@ffmpeg.org Date: Sat, 23 Mar 2024 03:06:10 +0100 Message-ID: X-Mailer: git-send-email 2.40.1 In-Reply-To: References: X-TMN: [xpT3mP7cqjLdTZRGXSgjIyzTj7orVooG2KHbiuv01Hw=] X-ClientProxiedBy: ZR0P278CA0005.CHEP278.PROD.OUTLOOK.COM (2603:10a6:910:16::15) To GV1P250MB0737.EURP250.PROD.OUTLOOK.COM (2603:10a6:150:8e::17) X-Microsoft-Original-Message-ID: <20240323020623.1570961-1-andreas.rheinhardt@outlook.com> MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: GV1P250MB0737:EE_|AM8P250MB0137:EE_ X-MS-Office365-Filtering-Correlation-Id: 2ad7a70e-fb7f-433d-8c65-08dc4adddb7c X-MS-Exchange-SLBlob-MailProps: Cq7lScuPrnqkjmXb1vlddM5aSa/Epk3AsQxdDK0Q8KgDxAec+s1xKNq01LgLGdiAtq3fImZHq2PN8aQxajwITTJJg/+M5bkvmHOaZlHDP9sBkANS4LAAdN5wzkCAx6pBWHUWFl9Av2P6QTqneW07nAIWgmqmRDwrYZf8n6YZNoMsj64lG5l+3dg4KK1I05Y3WmfiRaLRDa3WJCngsDIH5tXxk+JFZAfBPwB/VtF504ub/6D8AYno1oLZg+rq1nKx5B+CoXayK27MSxKHF6wG1OeFkW/TtgRJVUcY99UnEhh59lMLd3YyphEAILcrK9pFJUw0nf1QN0QbFCTFJzCJcHZr1gYcNGLG/2IFnb0YtQKSrJjd9hDdd4kXiAy54v1S26ldD3QJWl1D6iLKB27oAkzUaFrXNLZfG1VstBXE+EOBsCGXJ6kSQW8yG/ZAjKUHvsM0CNmw0HMqtLm1fs+UsOJ8eUFhq3hzYZSMsiyyYYeS8DcrlffWxImP0OLrWxo6vxBLcbch2/RtsX5gUtJkGi2ymb3FjdNn4KWWA94cWxUfqPH4gNIMmGWExH9cjIBK1eHTbPpSjyXzllNqtadXWg9hI6K/q8+DU/fEIhNdLJjHtP5t2RKov8tucWu9gDFofSNAVNoWfJSsi7eJ9f9YZ9kSGFd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UQkrOqig== X-OriginatorOrg: outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: 2ad7a70e-fb7f-433d-8c65-08dc4adddb7c X-MS-Exchange-CrossTenant-AuthSource: GV1P250MB0737.EURP250.PROD.OUTLOOK.COM X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 23 Mar 2024 02:06:31.2581 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 84df9e7f-e9f6-40af-b435-aaaaaaaaaaaa X-MS-Exchange-CrossTenant-RMS-PersistedConsumerOrg: 00000000-0000-0000-0000-000000000000 X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM8P250MB0137 Subject: [FFmpeg-devel] [PATCH 02/15] avformat/hls: Don't access FFInputFormat.raw_codec_id 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 Cc: Andreas Rheinhardt Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" X-TUID: 6S43nN6u8FPt It is an implementation detail of other input formats whether they use raw_codec_id or not. The HLS demuxer should not rely on this. Signed-off-by: Andreas Rheinhardt --- libavformat/hls.c | 10 ++++++---- libavformat/hls_sample_encryption.c | 1 + 2 files changed, 7 insertions(+), 4 deletions(-) diff --git a/libavformat/hls.c b/libavformat/hls.c index f6b44c2e35..94defa9384 100644 --- a/libavformat/hls.c +++ b/libavformat/hls.c @@ -2100,10 +2100,12 @@ static int hls_read_header(AVFormatContext *s) */ if (seg && seg->key_type == KEY_SAMPLE_AES && pls->is_id3_timestamped && pls->audio_setup_info.codec_id != AV_CODEC_ID_NONE) { - void *iter = NULL; - while ((in_fmt = av_demuxer_iterate(&iter))) - if (ffifmt(in_fmt)->raw_codec_id == pls->audio_setup_info.codec_id) - break; + av_assert1(pls->audio_setup_info.codec_id == AV_CODEC_ID_AAC || + pls->audio_setup_info.codec_id == AV_CODEC_ID_AC3 || + pls->audio_setup_info.codec_id == AV_CODEC_ID_EAC3); + // Keep this list in sync with ff_hls_senc_read_audio_setup_info() + in_fmt = av_find_input_format(pls->audio_setup_info.codec_id == AV_CODEC_ID_AAC ? "aac" : + pls->audio_setup_info.codec_id == AV_CODEC_ID_AC3 ? "ac3" : "eac3"); } else { pls->ctx->probesize = s->probesize > 0 ? s->probesize : 1024 * 4; pls->ctx->max_analyze_duration = s->max_analyze_duration > 0 ? s->max_analyze_duration : 4 * AV_TIME_BASE; diff --git a/libavformat/hls_sample_encryption.c b/libavformat/hls_sample_encryption.c index d5b4c11b66..f412836d4f 100644 --- a/libavformat/hls_sample_encryption.c +++ b/libavformat/hls_sample_encryption.c @@ -64,6 +64,7 @@ void ff_hls_senc_read_audio_setup_info(HLSAudioSetupInfo *info, const uint8_t *b info->codec_tag = AV_RL32(buf); + /* Always keep this list in sync with the one from hls_read_header() */ if (info->codec_tag == MKTAG('z','a','a','c')) info->codec_id = AV_CODEC_ID_AAC; else if (info->codec_tag == MKTAG('z','a','c','3')) From patchwork Sat Mar 23 02:06:11 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andreas Rheinhardt X-Patchwork-Id: 47351 Delivered-To: ffmpegpatchwork2@gmail.com Received: by 2002:a05:6a21:1014:b0:1a3:ac71:9534 with SMTP id nk20csp285741pzb; Fri, 22 Mar 2024 19:06:51 -0700 (PDT) X-Forwarded-Encrypted: i=2; AJvYcCWfp8spG8ubB0MkMdNKIbWRT5atOhEARGu5MHYRSUJ2p++ZKqPEz028uwZ21Ab28UCs8r9llePa5AqHjN3jFuMHqB8q3zwB4ZM8vA== X-Google-Smtp-Source: AGHT+IEQXniwXWJrwVELgPZCDwVL046N6oZfyLOHNNxkLViZadTpCZIkaeNERk78o5sv0u1Jt740 X-Received: by 2002:a05:6512:456:b0:513:2b35:2520 with SMTP id y22-20020a056512045600b005132b352520mr648871lfk.58.1711159611169; Fri, 22 Mar 2024 19:06:51 -0700 (PDT) Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org. [79.124.17.100]) by mx.google.com with ESMTP id 7-20020a170906328700b00a46e35d488csi376924ejw.306.2024.03.22.19.06.50; Fri, 22 Mar 2024 19:06:51 -0700 (PDT) Received-SPF: pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) client-ip=79.124.17.100; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@outlook.com header.s=selector1 header.b=E6QhOqju; arc=fail (body hash mismatch); spf=pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) smtp.mailfrom=ffmpeg-devel-bounces@ffmpeg.org; dmarc=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=outlook.com Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id 462BD68D5A8; Sat, 23 Mar 2024 04:06:45 +0200 (EET) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from EUR04-DB3-obe.outbound.protection.outlook.com (mail-db3eur04olkn2050.outbound.protection.outlook.com [40.92.74.50]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id F241368D022 for ; Sat, 23 Mar 2024 04:06:37 +0200 (EET) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=d9ao4BqhnOk8trazMQzciM+rieptkR9ziPwo0d8U4xGOegLQUH4yKlyl1JfI/2Tv+UBecAs9mpjEvIof7t9P23gpp9XMFViLY47puTJvlPl1lXgEaYr8AK1336hne/Me5CcOLN1/60ef41fZ/yFVPeTDzFdqWk6iX1FpfyrjMd1B9E0WxHSartslo9+Vv7JO9WY//YBURiui6Yu5TeLXjZMlpdAwFfK1uEs+SCao0UGS+Lg3+mmzdqAS0Lir0mXhnJtrwr4TpRC0+nHhhNS9I4SfOfTP7ipa/rwqj38Yk9vMp9IeSR+In4/HQoRqwVQN/cELxR/HaNgsa4ougUajJA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=quB8mw2Ha/rVF/is7Rk96NNaKcMJsPrX/2QGnSV9tSA=; b=HyiGSshxO0n5GDBmTsWyte/BaCKqb0xElLm33v04CCVWLIr5qjpY8PIS1Nu2oJIF6z2cweCkiCb4ZRSd3Jcg8GO844xriNLLcRTznkpREGMMK+8nfSV4pb9d7ndSkYFM6ptsS89tK5+w1EgN+bAgZBN/P4WAHsahRZCuIZTudOESNX5QkSXn4roqQC7TRpTrjITt3cFp4H5k5AvpQ+5kkv/cVTqxnZVDwMUmweWFhsNpac+U03CWGeAoXomuSB2MADXZ3bHqTB/nWRMD9JQBNuf2Ohp8H7cdM+8pX5Lf0GLMBBEKnj/52bz5/sAjMeJZhgYiH7cakLxW9reFior3wg== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=none; dmarc=none; dkim=none; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=outlook.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=quB8mw2Ha/rVF/is7Rk96NNaKcMJsPrX/2QGnSV9tSA=; b=E6QhOqjusSTqtp32Y44MZSah9MEsX2gyIwhuzQrxg1MvrrcL9U+XB28TlpwHALBeDQ1cX64KgAi00kqiamXVNeB/pcZiqvOykkHeFj95SgSLQwEEJlw5V7+GSQ73syJceuLuCFNgPs8fYYUAR4lnvo3V4R4bKq9sJnxRosbv5WB8AiA3z43PAWwdTN4/hHPSBrUsDcdJoXHUn8Q/6pemc39K5vbPUAO6N451O6FqRD4In/KSxeV5vWedWsUDYgaJcDs5H5rT2NzV5o2zuB39d/O/B57LqktE/qTUb7PJ4Q7AtExIJsNbhs1yM+weSV4KAeqtt9Iuw6u2PaOYKQ0SaQ== Received: from GV1P250MB0737.EURP250.PROD.OUTLOOK.COM (2603:10a6:150:8e::17) by AM8P250MB0137.EURP250.PROD.OUTLOOK.COM (2603:10a6:20b:320::11) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7409.24; Sat, 23 Mar 2024 02:06:33 +0000 Received: from GV1P250MB0737.EURP250.PROD.OUTLOOK.COM ([fe80::4a3b:cf76:cddc:c68d]) by GV1P250MB0737.EURP250.PROD.OUTLOOK.COM ([fe80::4a3b:cf76:cddc:c68d%4]) with mapi id 15.20.7386.025; Sat, 23 Mar 2024 02:06:33 +0000 From: Andreas Rheinhardt To: ffmpeg-devel@ffmpeg.org Date: Sat, 23 Mar 2024 03:06:11 +0100 Message-ID: X-Mailer: git-send-email 2.40.1 In-Reply-To: References: X-TMN: [Yn6bD57ir7Tq7RdGAXJgg14k5UeAJAVEZlQ1rWhYPEA=] X-ClientProxiedBy: ZR0P278CA0005.CHEP278.PROD.OUTLOOK.COM (2603:10a6:910:16::15) To GV1P250MB0737.EURP250.PROD.OUTLOOK.COM (2603:10a6:150:8e::17) X-Microsoft-Original-Message-ID: <20240323020623.1570961-2-andreas.rheinhardt@outlook.com> MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: GV1P250MB0737:EE_|AM8P250MB0137:EE_ X-MS-Office365-Filtering-Correlation-Id: fe6e3c97-1f1f-4aa2-ddd3-08dc4adddc8a X-MS-Exchange-SLBlob-MailProps: Cq7lScuPrnqkjmXb1vlddM5aSa/Epk3Avcf2FPioCve9ssXv7eqtGJv4lSyo9jxO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Rd+0Ikrco6FRUK9a9wttjoysUgHlTpGVZc+Qw3sydFWS/pGB9A7OiWmgYyNQTluiU/rebgy/MPuG6BvXFzCi44AFiX2GQKyGXeE+e8yShV41U4DS2dyN3znCInJJ0ceG3RLN0/p7Rs/9AAWhze2wMFLbmTTb9Cu3QgvaB4dLmlIhejd+ab2RFjGNgnQ+o4XOlFaDA13b1aleSJYCs7T6oksHDDWOWVqd+llFdp2N7RANL6V/wR3Ccf4+izEQgSfUkaFDs/0h4TbQLZYmQu/WiHEAeIP+GT55BC4r2mEMFwwR+LBRRO/tAp3QokGlSvgI8M1ojEnUC8LAfgeQFgG0NX5JJFZYr/oGRWj++x/lXCyomF2IIsyCtdYWoI3eP4ShOJeR3X+QeYdt1TZ9UauqeV4sGRKF7/T+VyBbsYmSP9MdScrj6l+AAwHTnSUvh0BQ/OZUcmpk+HcaRnpYJEtoeikRjcnOpUvrVpJStMzEy7CzJQu9bxP/l1sqU7dYu+7a52qu1my+sjPAdhxP13gp3TpwfVoRAKE6F9PmdrOm31OXxJZL2LiHDlXizHGjxltpmN3R+tXG1zCTClWkxKBJPIhfOY4B6yMfLwA== X-OriginatorOrg: outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: fe6e3c97-1f1f-4aa2-ddd3-08dc4adddc8a X-MS-Exchange-CrossTenant-AuthSource: GV1P250MB0737.EURP250.PROD.OUTLOOK.COM X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 23 Mar 2024 02:06:33.0271 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 84df9e7f-e9f6-40af-b435-aaaaaaaaaaaa X-MS-Exchange-CrossTenant-RMS-PersistedConsumerOrg: 00000000-0000-0000-0000-000000000000 X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM8P250MB0137 Subject: [FFmpeg-devel] [PATCH 03/15] avformat/fitsdec: Don't use AVBPrint for temporary storage 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 Cc: Andreas Rheinhardt Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" X-TUID: KtQej2VeHguJ Most of the data in the temporary storage ends up being returned to the user as AVPacket.data, so it makes sense to avoid using the AVBPrint for temporary storage altogether (in particular in light of the fact that the blocks read here are too big for the small-string optimization anyway) and read the data directly into AVPacket.data. This also avoids another memcpy() from a stack buffer to the AVBPrint in ts_image() (that could always have been avoided with av_bprint_get_buffer()). These changes also allow to use av_append_packet(), which greatly simplifies the code; furthermore, one can avoid cleanup code on error as the packet is already unreferenced generically on error. There are two user-visible changes from this patch: 1. Truncated packets are now marked as corrupt. 2. AVPacket.pos is set (it corresponds to the discarded header line, 80 bytes before the position corresponding to the actual packet data). Furthermore, this patch also removes code that triggered a -Wtautological-constant-out-of-range-compare warning from Clang (namely a comparison of an unsigned and INT64_MAX in an assert). Signed-off-by: Andreas Rheinhardt --- libavformat/fitsdec.c | 80 ++++++++++++++----------------------------- 1 file changed, 25 insertions(+), 55 deletions(-) diff --git a/libavformat/fitsdec.c b/libavformat/fitsdec.c index fe2dd5ad5d..6771dda327 100644 --- a/libavformat/fitsdec.c +++ b/libavformat/fitsdec.c @@ -24,13 +24,10 @@ * FITS demuxer. */ -#include "libavutil/avassert.h" -#include "libavutil/intreadwrite.h" #include "demux.h" #include "internal.h" #include "libavutil/opt.h" #include "libavcodec/fits.h" -#include "libavutil/bprint.h" #define FITS_BLOCK_SIZE 2880 @@ -71,31 +68,31 @@ static int fits_read_header(AVFormatContext *s) * @param s pointer to AVFormat Context * @param fits pointer to FITSContext * @param header pointer to FITSHeader - * @param avbuf pointer to AVBPrint to store the header + * @param pkt pointer to AVPacket to store the header * @param data_size to store the size of data part - * @return 1 if image found, 0 if any other extension and AVERROR_INVALIDDATA otherwise + * @return 1 if image found, 0 if any other extension and AVERROR code otherwise */ -static int64_t is_image(AVFormatContext *s, FITSContext *fits, FITSHeader *header, - AVBPrint *avbuf, uint64_t *data_size) +static int is_image(AVFormatContext *s, FITSContext *fits, FITSHeader *header, + AVPacket *pkt, uint64_t *data_size) { int i, ret, image = 0; - char buf[FITS_BLOCK_SIZE] = { 0 }; - int64_t buf_size = 0, size = 0, t; + int64_t size = 0, t; do { - ret = avio_read(s->pb, buf, FITS_BLOCK_SIZE); + const uint8_t *buf, *buf_end; + ret = av_append_packet(s->pb, pkt, FITS_BLOCK_SIZE); if (ret < 0) { return ret; } else if (ret < FITS_BLOCK_SIZE) { return AVERROR_INVALIDDATA; } - av_bprint_append_data(avbuf, buf, FITS_BLOCK_SIZE); ret = 0; - buf_size = 0; - while(!ret && buf_size < FITS_BLOCK_SIZE) { - ret = avpriv_fits_header_parse_line(s, header, buf + buf_size, NULL); - buf_size += 80; + buf_end = pkt->data + pkt->size; + buf = buf_end - FITS_BLOCK_SIZE; + while(!ret && buf < buf_end) { + ret = avpriv_fits_header_parse_line(s, header, buf, NULL); + buf += 80; } } while (!ret); if (ret < 0) @@ -142,12 +139,10 @@ static int64_t is_image(AVFormatContext *s, FITSContext *fits, FITSHeader *heade static int fits_read_packet(AVFormatContext *s, AVPacket *pkt) { - int64_t pos, ret; uint64_t size; FITSContext *fits = s->priv_data; FITSHeader header; - AVBPrint avbuf; - char *buf; + int ret; if (fits->first_image) { avpriv_fits_header_init(&header, STATE_SIMPLE); @@ -155,57 +150,32 @@ static int fits_read_packet(AVFormatContext *s, AVPacket *pkt) avpriv_fits_header_init(&header, STATE_XTENSION); } - av_bprint_init(&avbuf, FITS_BLOCK_SIZE, AV_BPRINT_SIZE_UNLIMITED); - while ((ret = is_image(s, fits, &header, &avbuf, &size)) == 0) { - av_bprint_finalize(&avbuf, NULL); - pos = avio_skip(s->pb, size); + while ((ret = is_image(s, fits, &header, pkt, &size)) == 0) { + int64_t pos = avio_skip(s->pb, size); if (pos < 0) return pos; - av_bprint_init(&avbuf, FITS_BLOCK_SIZE, AV_BPRINT_SIZE_UNLIMITED); avpriv_fits_header_init(&header, STATE_XTENSION); + av_packet_unref(pkt); } if (ret < 0) - goto fail; - - if (!av_bprint_is_complete(&avbuf)) { - ret = AVERROR(ENOMEM); - goto fail; - } - - av_assert0(avbuf.len <= INT64_MAX && size <= INT64_MAX); - if (avbuf.len + size > INT_MAX - 80) { - ret = AVERROR_INVALIDDATA; - goto fail; - } - // Header is sent with the first line removed... - ret = av_new_packet(pkt, avbuf.len - 80 + size); - if (ret < 0) - goto fail; + return ret; pkt->stream_index = 0; - pkt->flags |= AV_PKT_FLAG_KEY; + pkt->flags |= AV_PKT_FLAG_KEY; + pkt->duration = 1; + // Header is sent with the first line removed... + pkt->data += 80; + pkt->size -= 80; - ret = av_bprint_finalize(&avbuf, &buf); - if (ret < 0) { - return ret; - } + if (size > INT_MAX - AV_INPUT_BUFFER_PADDING_SIZE - pkt->size) + return AVERROR(ERANGE); - memcpy(pkt->data, buf + 80, avbuf.len - 80); - pkt->size = avbuf.len - 80; - av_freep(&buf); - ret = avio_read(s->pb, pkt->data + pkt->size, size); + ret = av_append_packet(s->pb, pkt, size); if (ret < 0) return ret; - pkt->size += ret; - pkt->duration = 1; - return 0; - -fail: - av_bprint_finalize(&avbuf, NULL); - return ret; } static const AVOption fits_options[] = { From patchwork Sat Mar 23 02:06:12 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andreas Rheinhardt X-Patchwork-Id: 47352 Delivered-To: ffmpegpatchwork2@gmail.com Received: by 2002:a05:6a21:1014:b0:1a3:ac71:9534 with SMTP id nk20csp285802pzb; Fri, 22 Mar 2024 19:07:01 -0700 (PDT) X-Forwarded-Encrypted: i=2; AJvYcCVMNuKIC+a/fzHTBe5nMTguaYFk/NkVvciHtuuK4MUOSgDkOjecejDo4zovp4g4Ll16S+QocdivYYGl8V7UY1k0dyVHFinmHcOkHQ== X-Google-Smtp-Source: AGHT+IF3/0aNOGB3yGzh6ZWKpqZCGGAz5Wb+8D9PeWN/MLAzIxuw/YqgLpG3p58Buk/UzJQvYiKN X-Received: by 2002:ac2:538c:0:b0:513:93dd:9ecd with SMTP id g12-20020ac2538c000000b0051393dd9ecdmr693469lfh.21.1711159621310; Fri, 22 Mar 2024 19:07:01 -0700 (PDT) Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org. [79.124.17.100]) by mx.google.com with ESMTP id w11-20020a170906d20b00b00a47358ae7e3si402802ejz.992.2024.03.22.19.07.00; Fri, 22 Mar 2024 19:07:01 -0700 (PDT) Received-SPF: pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) client-ip=79.124.17.100; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@outlook.com header.s=selector1 header.b=g9Hq+7fe; arc=fail (body hash mismatch); spf=pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) smtp.mailfrom=ffmpeg-devel-bounces@ffmpeg.org; dmarc=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=outlook.com Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id 6050568D5B6; Sat, 23 Mar 2024 04:06:50 +0200 (EET) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from EUR04-DB3-obe.outbound.protection.outlook.com (mail-db3eur04olkn2050.outbound.protection.outlook.com [40.92.74.50]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id 2355168D5B1 for ; Sat, 23 Mar 2024 04:06:43 +0200 (EET) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=Xmlst7ZWNQ/ejJpwCFgeIdyKk4uqWGiJVTZFzVEVlp/witR80JzrvghagdaMFBzmW6zRAYW/lkzEhl+Lj9pSrMQjfwQkHW/rgIBTqV/OUo2EStJjABUYCP+E2N9dv1C1q3l86yEOx4Lym20IvzqeuD9Sm4CCLyLJ0ZPmKyVq2KH5KL9OMG+jwtyW0ba2TMLTe4Usxx4Cm0hEcvHr28xA2WPS140jJBa2BBfoeqfgvWPqyBVugJ6frF5QlF4v1nid1ch5iPeS9lMlLjVreNAMxOiwedGEgGxULFK/hglktW9C3NVW79YB/OYIIc0asxDyxQThxMRKaDrcKIyslAMv6w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=Pduxyj4NVJ/uaEKkmH7RFm8P/De0C1gy6fOGYAIUgsE=; b=IciZktVjBvmMihPN0ZHK/nFebCj+EjKLQHSAJXEck0A6w3ehpFLlbdFRf475xLUMzwZ6mgpdxvq8gMSlq1NFbhlxlhgXNvHXagjdK6uFg9NUobrn5lZUtBxfB44fdS7mn8Lx7coKD4cllHGgq5nT8kOHtapyoIvLVZVT4Il41INeZFD13uXkKn5DIx6lhsJl2ibjT+kXRyltcJS4cO61gJgBz2QvVlHYBqHEgHsEv2TLlmoTiKge1Xhg0sRQBScqZ5EhU4KbP8FNvkHrDpSA8EsSWDFOzi8UXYI/gvWnF1KmCCMsGUi8iUlYHE+uMCXkjYVPklRk7pJnIoHujuDqcw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=none; dmarc=none; dkim=none; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=outlook.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=Pduxyj4NVJ/uaEKkmH7RFm8P/De0C1gy6fOGYAIUgsE=; b=g9Hq+7fez1mxDsX93yz6jmrsxDixTFzMw4iQJRXF3CUIyYUgDKV/yx9vhV9vtjm4aKI0bRPNMHXbvNRvLbAoVhenRpw4hE0bEP6WV8WHi4h04SFaYY+G6Yp96PKleP9C8kgEDUV4D35WM4VFm+vQubnmJmfBJI07gWe1BaTCWvl2xq8PvhwabCNEUrccX8CdIsjgFZpe27Mg1tlYkL6a7jqMXqn0JbTMB2AtkrYPgTjs1y4++smajltv8WKmgKukUPR2uJ6NthRclIUtP+LLmJXidf9/53oGM7wppVpHvzYYrRNAuZT3VFXjSS3VqaFMgZr8x+uk+yxfF/4KbTd81Q== Received: from GV1P250MB0737.EURP250.PROD.OUTLOOK.COM (2603:10a6:150:8e::17) by AM8P250MB0137.EURP250.PROD.OUTLOOK.COM (2603:10a6:20b:320::11) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7409.24; Sat, 23 Mar 2024 02:06:34 +0000 Received: from GV1P250MB0737.EURP250.PROD.OUTLOOK.COM ([fe80::4a3b:cf76:cddc:c68d]) by GV1P250MB0737.EURP250.PROD.OUTLOOK.COM ([fe80::4a3b:cf76:cddc:c68d%4]) with mapi id 15.20.7386.025; Sat, 23 Mar 2024 02:06:34 +0000 From: Andreas Rheinhardt To: ffmpeg-devel@ffmpeg.org Date: Sat, 23 Mar 2024 03:06:12 +0100 Message-ID: X-Mailer: git-send-email 2.40.1 In-Reply-To: References: X-TMN: [9s4wMYxY6b8K7SgQdvvNqIbdmh7pLvGJUDFqo3ZmVGc=] X-ClientProxiedBy: ZR0P278CA0005.CHEP278.PROD.OUTLOOK.COM (2603:10a6:910:16::15) To GV1P250MB0737.EURP250.PROD.OUTLOOK.COM (2603:10a6:150:8e::17) X-Microsoft-Original-Message-ID: <20240323020623.1570961-3-andreas.rheinhardt@outlook.com> MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: GV1P250MB0737:EE_|AM8P250MB0137:EE_ X-MS-Office365-Filtering-Correlation-Id: cc16af4e-0603-437e-9aca-08dc4adddd26 X-MS-Exchange-SLBlob-MailProps: Cq7lScuPrnqkjmXb1vlddM5aSa/Epk3A+VhfcnrVACgs6QaDndxlgvqtQ2kV56KANKnH/mGFAxfMLYRPDj97kFmDwNbBc0AIb9Ma75TSigVF8OV6ydxvT14Qs2a2uo4SV+xJWY1/85Pp9AfdJ6Sn8gnkcOCs/v7JrJftwkVZz/vxzqQXrVh9e9iOQxWytLLWHzWVmWBFgeoe/XUN+83HUPOfGSPOCuKlRL6cbdd53CV8zClAFfF5jAHTD+ma7Hh3BxMsUnaVRi5NSCfLkJaxrAabuXhVvoJwBaBeuq7Y2fPXNgzyrhflGeJteu9TcFxpDAkYC2ATIcTXXDkkwvK+wnCny1GW8lf10mTixA7W2dliaH12LzkrMzlf1NQXJJ5bDpXM5ETxcocojIlnxUG7oPsCs75RG/ubhRSNMIhZUfkbOjwv/LhMng6NZifLUU3Cu3Jhk/h1qzn6t8LQjRm4egiqOwpXKkRK5PKKI8DajJLPezjhBI+CVIgTsSz7a534QaPdM8T11Z6Oh1FxitJPw9NcEU1dK8aYSQHmmyiDgCeHl/uayTfb7mEL7uAaIpbonmjHbzJFaDjTEzsJ599XJ7MFqwsjYHHWA2hF8JtoZyXJNwyhENVYBKAlTpPgmSOEi5S4LQSs+44G52kckcITovZ9+xDtUn5ptqpSSpRr2AVgDX6cVla5z3iVEuhcMNdGp71LWapNIS+at2GpQKnXyAIG6wlNIdI+RaQVinAxYVLA1UHPkPka618zF7TJrJPXCE1Qh4Fo6tw= X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: +foKMya14VtJljupeE3eb6btwSCmLuIpfajLMNJUCbjztiuhdzkWO19cJkqhcmgEI4f8RSalFXJ5BnG3rYBjwBN+dxif0J+IeZ9pJmUBr4KKpbLpv4s/SsJUpKzRUgiWLRYudWodVA5o+X8mBt1ZyVj8JJufz2SwIDsEl09zPK1TMY2dD18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xF569MlEiNl+KI39wzpAJLURSFW6qzd0fXwNDMunlcnTCwUQe9jNDMj97iIovju0nhQWCaEXRE4F54fzbNrVFpeJzFI7Iw+qYNJBt2olWKn1SKeKOs0QHYmn0jLpITc/sKJG+quiLL6WX6xnZrB5LM/46MQP+x7RHe0p+cswauTgQJF2tkSSN9k+19NwRfFGlWECsUHADi9NPCyKZ0nPv9cD4SM1rRx/RAPpkQpkXQkJurDj5ipLmhCoLEwsk65UajHThiGhVb1GbsrR4Ozh2o4iFPmrq90qGRTbcYbykCS+/kC12bu0RKn/PYIvCHSbcGuadgy/Q3IJNK8G/w/dGCO80mhCso6QEAgmNd9uhHSKNegFSyK6Lh6VquLUESn8g1RGEsmYIdlhUFFwifm/MD7yYGpgGMPvYutEiq17leLjuaU/6oSk5JUdZlCAfI61Q7dmh0Z+HIiWpe3H3j7suL7iXXNKAqsKa9DifaMWAembWgUm+zLJlD8lq085wqi4/tlUMAca3GlVS3TvqFMr5ius1X1IKxUFNkXv0qB7EZbFYl/PYNQ0HORuh+gZVATy4FWAUK6sl33lUJmDAW9Up0QZXlfV7oeU9OWGBHEJ0EdroNjTmmZSv3vowLPG/B0r2yGlElosG2osyb0/rMjT7A9DdgwyXXgwBpYnERitxkpMjgASbfNIIxCW104bv3YQ0ZifvKeEGnXa06N298GsdLnYf3NPMmIMkDZzAFhOkyRyykjGiA== X-OriginatorOrg: outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: cc16af4e-0603-437e-9aca-08dc4adddd26 X-MS-Exchange-CrossTenant-AuthSource: GV1P250MB0737.EURP250.PROD.OUTLOOK.COM X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 23 Mar 2024 02:06:34.1242 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 84df9e7f-e9f6-40af-b435-aaaaaaaaaaaa X-MS-Exchange-CrossTenant-RMS-PersistedConsumerOrg: 00000000-0000-0000-0000-000000000000 X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM8P250MB0137 Subject: [FFmpeg-devel] [PATCH 04/15] avformat/g722: Inline constants 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 Cc: Andreas Rheinhardt Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" X-TUID: DXZBnt2QEhJw Forgotten in 5f0e161dd61552ad70760bad35b869eaec7368ff. Signed-off-by: Andreas Rheinhardt --- libavformat/g722.c | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/libavformat/g722.c b/libavformat/g722.c index 15519d90b5..adb78e8db5 100644 --- a/libavformat/g722.c +++ b/libavformat/g722.c @@ -19,7 +19,6 @@ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA */ -#include "libavutil/avassert.h" #include "avformat.h" #include "demux.h" #include "internal.h" @@ -38,10 +37,7 @@ static int g722_read_header(AVFormatContext *s) st->codecpar->sample_rate = 16000; st->codecpar->ch_layout = (AVChannelLayout)AV_CHANNEL_LAYOUT_MONO; - st->codecpar->bits_per_coded_sample = - av_get_bits_per_sample(st->codecpar->codec_id); - - av_assert0(st->codecpar->bits_per_coded_sample > 0); + st->codecpar->bits_per_coded_sample = 4; avpriv_set_pts_info(st, 64, 1, st->codecpar->sample_rate); return 0; From patchwork Sat Mar 23 02:06:13 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andreas Rheinhardt X-Patchwork-Id: 47353 Delivered-To: ffmpegpatchwork2@gmail.com Received: by 2002:a05:6a21:1014:b0:1a3:ac71:9534 with SMTP id nk20csp285867pzb; Fri, 22 Mar 2024 19:07:09 -0700 (PDT) X-Forwarded-Encrypted: i=2; AJvYcCVAS24lcTPEMmhf7+BOzAEK0C/LW4ZbdRq/Eu8jlE7SQPxLJT4k+vurRRnpS6AW+AYeWVc7IDf3eRB+7Om0g7sqvcICBI2DU1wO+w== X-Google-Smtp-Source: AGHT+IHAqrNwN/jekjD9U63Wj34LPeTl/HTaAWA8fV50yFyl4FTSr9PXpB+Y8xwEPZMWKIbjdFMq X-Received: by 2002:a50:874b:0:b0:567:156e:7893 with SMTP id 11-20020a50874b000000b00567156e7893mr667768edv.4.1711159629643; Fri, 22 Mar 2024 19:07:09 -0700 (PDT) Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org. [79.124.17.100]) by mx.google.com with ESMTP id dn9-20020a05640222e900b00568cd3deeccsi358864edb.480.2024.03.22.19.07.09; Fri, 22 Mar 2024 19:07:09 -0700 (PDT) Received-SPF: pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) client-ip=79.124.17.100; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@outlook.com header.s=selector1 header.b=DRL78bup; arc=fail (body hash mismatch); spf=pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) smtp.mailfrom=ffmpeg-devel-bounces@ffmpeg.org; dmarc=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=outlook.com Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id 6D3FA68D5CF; Sat, 23 Mar 2024 04:06:51 +0200 (EET) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from EUR04-HE1-obe.outbound.protection.outlook.com (mail-he1eur04olkn2090.outbound.protection.outlook.com [40.92.73.90]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id 625E368D593 for ; Sat, 23 Mar 2024 04:06:44 +0200 (EET) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=iEnhiO0RByKfKe3Bs4mEddD9xCHvDzWicm1J6NVrhSyB5lK6mwlPV0s0wdsmcC9vLKH/PXzkvMyVxg+UMzxDsFds/+Y+w5BJDOoP2QuwfuMNqQFK18itO9Hh9ka2LWx+nby75RCDtRX/cjZb3j6wJfPKD4F7+ugAehZuctrFK39R6SKH1wP07b1JiLiGe/88fYEGjXNSJM1+9Ubn5Qo7oGp95k2KsnsgQXl+4euqexZwuXK7/ek2Vteo1poCpYBffi3ZqaV4npmXktTT8qzPSgbt82vY1NOhIO7Hb5jP98ERFUzMcjFjY7zZ/HsmWRONssB+mJIPS/tv9XF2ScAYRQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=PEERX6A/GWMMVeeAjTxwv/ZUiJ0Yc8YOqYWrKX3er+o=; b=GgPoXJGZDn5DTbF8x8wP+D2gwaIwE9dEzkE2AQP/idLFEQtVbiN/B1xRLTLX9RtwXYSL++yCu3xQ4WtiobrJ3FA8uMAjWdgsATIv42lXdUp+LD7tbRXg1MX7kzfGrJ84dtr3j490cc5IHR/RtBYXcfeFBM7+auI+CGdWamt5kxTAspj/jTAY4stjcM4D9O16MorTdR7Qlsi/Px8YuN3EDta78YoV5nqnikqD4RIRWcm2RXpL0ijtn/xPV1H6EjJynEvBo9lUtglH38M3sAgvHdbHrKi0VlLHDtcvDLWM5HbReVkxrK5eEnhXXeQvCxbCRIHsCNzpKtn/UuzQS0wXlg== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=none; dmarc=none; dkim=none; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=outlook.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=PEERX6A/GWMMVeeAjTxwv/ZUiJ0Yc8YOqYWrKX3er+o=; b=DRL78bupOoQGBC5sKenwbUx33f/x/APEqz8uwv1ICFBV/vt5uH5DmvdID34O8FHKf75gIqkXFt1oX+4v/T+lE2H2gH6FZKXkyRQKCq5n0ZmL5Gwo7E6hNME9mPJLUDReIWKgIIzHoOurNLZ8nKZZ5+ciD/2Yuh87y4cuUG8HT0XAatW7mSC2vv0DZpQYr63T2LtbxEgkjajlSYqpzO5MqoC4SU+W7XxXS+SynP9f6D+wW/+ZAK7zszNJZ75ChQa/4F3w8JoFWqV8tYUWo0o9/+EvROX7BeJWpyqpWa++m8/+clo4a4bF0GfD+Kk5N8plaGbP0Ygz5o27iy/zqinqFw== Received: from GV1P250MB0737.EURP250.PROD.OUTLOOK.COM (2603:10a6:150:8e::17) by AM8P250MB0137.EURP250.PROD.OUTLOOK.COM (2603:10a6:20b:320::11) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7409.24; Sat, 23 Mar 2024 02:06:35 +0000 Received: from GV1P250MB0737.EURP250.PROD.OUTLOOK.COM ([fe80::4a3b:cf76:cddc:c68d]) by GV1P250MB0737.EURP250.PROD.OUTLOOK.COM ([fe80::4a3b:cf76:cddc:c68d%4]) with mapi id 15.20.7386.025; Sat, 23 Mar 2024 02:06:35 +0000 From: Andreas Rheinhardt To: ffmpeg-devel@ffmpeg.org Date: Sat, 23 Mar 2024 03:06:13 +0100 Message-ID: X-Mailer: git-send-email 2.40.1 In-Reply-To: References: X-TMN: [CBk5Svr1WWKuborQ40VyVDPe9wT/ZoDt80GvWUn9XGw=] X-ClientProxiedBy: ZR0P278CA0005.CHEP278.PROD.OUTLOOK.COM (2603:10a6:910:16::15) To GV1P250MB0737.EURP250.PROD.OUTLOOK.COM (2603:10a6:150:8e::17) X-Microsoft-Original-Message-ID: <20240323020623.1570961-4-andreas.rheinhardt@outlook.com> MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: GV1P250MB0737:EE_|AM8P250MB0137:EE_ X-MS-Office365-Filtering-Correlation-Id: 7a0c8369-efed-47fb-490a-08dc4addddd6 X-MS-Exchange-SLBlob-MailProps: Cq7lScuPrnqkjmXb1vlddM5aSa/Epk3AFc0Lw9yFxc8x57dQedbEwEgY1S5fsmFUYE0B81UUWTQauNVb0SAmGY3skX/vvthcxQ1W00D0/0SJgbJEwyIOgk7YqMNCefruc5a8Wyq8gY894CFfi4s9Pn8SMK/RC1TtMiZRys0X2rxx1/dA7APs61iEUyHJhJw2NlWbTw7ghTy1I18Ogjm9SzNDo5DCSFsp7DRhVeYFekUTPT2xZbmHVvjeyPsioxtQmJrvDeHXvtPgBSoDJbzDZdel6X3jhA4TZDYP0vwQjTNnzFCtvR+jp8ERwTAZkQH2mDO3WN2ipN7rhVTwiQ1CnZFr2fCxhncUsDY5urH94t7QRivDSQJV79FUBsETIVffuHXl/lgiQeoDKl2BGck+yVQrGn2IeiPMwuY+Mra7ZMP2a1uz8fzAHB+zCoDVuOry2RZ40L0ysL56kOpHAifXGNtAH7Voi4xhZZ6h/2rLYTeDX2T1KMPSH5QdRfTszV31xwGK3sSSBH0wwpAh67tZB5hu4VKd9BUuJI8Zofd7DlTaX7RD1KS7+jFLroJp1a3nLiIQmbOg/sWCoAqBuqlT3gM4Gi+vI1P0PckMpkrk1efvjt3wMUoD9WZy3OzQwGdpzYehmIWYe1XTomJZfTAtYCLN/wo/ngvay3jnYAfL1G3AVThI1c5ZV8ZrPKZgRlhjZForx8nglwAquHY5EBGQ4jABvIbprSNhR1pJifZdAhkYQeWEar3yso7IhKqSIASpsqdi9eDba1M= X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: KFgCP7+rPoM2UTUSsIVGmrGWqcoAtfrtpBiC8/omHFTKxJy45kvVcG+GdsEMyGA9cRaIGHBr79YXP8cziVy5HEQkALqWjhJXedamfQh3b7nI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l2MaX2oNp7UkjS4sS0NBlmSkoGGiIY/3R37CBijfWu5TtUmJ1vaUhX3nnzQ2cmJxK8kBgnl46vX8eXd+MGvC8EA3ADbZCd3Pz7n0MS1jwJ9jQbFwo8JeQcAyjk6l/iSTHWm4BGomidH7kNlJ9GHgzMYKhDXqzDKg9DRTieY3piaTTncTbKVjNz7SZyHzulVM8mlcH6PaT4Bw+7ETINyp4s9QT/69OtF7P+leGRLhMp8jz/hM0T9jxq2Pso9Gr3nqEmCkRYNQQMl9R7AXe4iVtsjnmSeU0SvMHLSbxF3Mo94wNwaPlDSTyIhp3BEtV4kc6mp5dP225HB5VLRbSEq3TVljEh27YHIogWL/vWnSVP+YQaOaa5PJJ1ACJS+FQI3FHSEekOJLYGxk316WID8qjSf1ACzSdn6VHmXXFwI1omS30wlB8uVXiK2T7W/TorKTEv5j4kJbOUeqiCe4c83QoqgfcgjZsDSog/Ohlksj7bGMA2zarFEfihYg6+oDLAY4V9AF5okXCog9aHiESnmwmDAsftdb+D0KyhHJnXaVpeBEzQWj1dTZCc+LIyBRpIY0dtsA/B3DQs1jF9K0637MdNbfGQvmnMTrE+rWHqbyPlwWODcXyCaeGC01XTpWmo+uE+TT/zFQTvQ51Ej3Fn9/APBbJgRIMTXfRGM9DJwiCcNDBRCwL5hUi15LeWzFpZmlPiPz2JsSNxjLyyfVinQnlNbjF2E5I0yPsHzcWU8N7HmiZgfImLhjElOwtuTUR+ELoXH3gRb/a0hMrGvj2gMAL8K998H9H/RLILKtvYNbvpob9l876jkeA== X-OriginatorOrg: outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: 7a0c8369-efed-47fb-490a-08dc4addddd6 X-MS-Exchange-CrossTenant-AuthSource: GV1P250MB0737.EURP250.PROD.OUTLOOK.COM X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 23 Mar 2024 02:06:35.2537 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 84df9e7f-e9f6-40af-b435-aaaaaaaaaaaa X-MS-Exchange-CrossTenant-RMS-PersistedConsumerOrg: 00000000-0000-0000-0000-000000000000 X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM8P250MB0137 Subject: [FFmpeg-devel] [PATCH 05/15] avformat/wvedec: Inline constant 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 Cc: Andreas Rheinhardt Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" X-TUID: ArHzyCcteQcz Signed-off-by: Andreas Rheinhardt --- libavformat/wvedec.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libavformat/wvedec.c b/libavformat/wvedec.c index 43e6359892..13934b78e4 100644 --- a/libavformat/wvedec.c +++ b/libavformat/wvedec.c @@ -45,7 +45,7 @@ static int wve_read_header(AVFormatContext *s) st->codecpar->codec_id = AV_CODEC_ID_PCM_ALAW; st->codecpar->sample_rate = 8000; st->codecpar->ch_layout.nb_channels = 1; - st->codecpar->bits_per_coded_sample = av_get_bits_per_sample(st->codecpar->codec_id); + st->codecpar->bits_per_coded_sample = 8; st->codecpar->block_align = st->codecpar->bits_per_coded_sample * st->codecpar->ch_layout.nb_channels / 8; avpriv_set_pts_info(st, 64, 1, st->codecpar->sample_rate); From patchwork Sat Mar 23 02:06:14 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andreas Rheinhardt X-Patchwork-Id: 47354 Delivered-To: ffmpegpatchwork2@gmail.com Received: by 2002:a05:6a21:1014:b0:1a3:ac71:9534 with SMTP id nk20csp285906pzb; Fri, 22 Mar 2024 19:07:18 -0700 (PDT) X-Forwarded-Encrypted: i=2; AJvYcCU9YgwsFXO3xfnHLb17PRTMd0IQgPD4Bz17IkzflD9nD3RbBWq5UPBarLj/GpiA99S5CzRc42R3UXvJdIVh15FAng16I0/3ykfnNg== X-Google-Smtp-Source: AGHT+IGUy/UqlvEr6Ib4wwntNNKTM2JCOI0GfxY73YzZYLShwGBf4p23KxO+hK7tY4hSOBFvJ5iz X-Received: by 2002:a50:a6d0:0:b0:568:8e22:4eff with SMTP id f16-20020a50a6d0000000b005688e224effmr650712edc.37.1711159638126; Fri, 22 Mar 2024 19:07:18 -0700 (PDT) Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org. [79.124.17.100]) by mx.google.com with ESMTP id m13-20020a056402510d00b00568a0a79b31si381928edd.128.2024.03.22.19.07.17; Fri, 22 Mar 2024 19:07:18 -0700 (PDT) Received-SPF: pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) client-ip=79.124.17.100; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@outlook.com header.s=selector1 header.b=Baf9I8Wp; arc=fail (body hash mismatch); spf=pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) smtp.mailfrom=ffmpeg-devel-bounces@ffmpeg.org; dmarc=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=outlook.com Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id 5D12668D5E0; Sat, 23 Mar 2024 04:06:54 +0200 (EET) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from EUR04-DB3-obe.outbound.protection.outlook.com (mail-db3eur04olkn2050.outbound.protection.outlook.com [40.92.74.50]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id 4B89368D5CB for ; Sat, 23 Mar 2024 04:06:48 +0200 (EET) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=YbRUCVxBeAs4WkelVlanJA6ZPa3iTyINR2Vq2N/xT2EnFCEI6WNM1hrV1f15L0zMxVxgS64nB0svm6coMKiAV0ObMWubNI6MjyA++fPu4a632ImRrmBSCUdBcREKJ/06KnP2Q3WGw7zmuS6UAjSBYRR5L5iMWB04bYU95RNciQduW9OYwU9QNIv+FEOUfge449W3oH80gJDcPDnA5iXEmat8LW216JayGaBnqlgSYZ+0qN8YVW4Rj7NX8baMAbemfVl5OrVUGgerldPeXjoh2lU2DMe+W8ZTQIECYqjCdlQ41+VBRbfY0vPuqxoo79B/5FLy2H+shnq+YuBGWXYKzA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=7/xiGPdhYX2NgJPkbiDzC345aJ0M6yyMi+ZYEwVBOBA=; b=b4C1PjhIdiy4buzvG+B6naTQRAHGSjPALzsIzCvR12YuKuWxPypwePW80kWqs/ILdz/j/8eQx5wlJXehrFKJBUF/I5oJUomBOin1Y2Yi3iShE9A29qt/V1N5dij1xD9BzE81AMu58tHaWzSqCu3vJkwy5Uwuiu9ZQTPi/bihCo2AxfDXLAQeVYLAvBelHlzKJrytR9Dot2SiTBvCrmZRQlUyoYmBrEWsi5q1yAA4kV5z6Kre83fBLZ02TWM3obf+uk6gfozPJ74TxishMBK2Rur52s+9BKJkn5hJ8iEllfqmhNcYpZ8NpQJ66LhpUhEzTAG+iTlyWiIy46P1T6C68Q== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=none; dmarc=none; dkim=none; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=outlook.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=7/xiGPdhYX2NgJPkbiDzC345aJ0M6yyMi+ZYEwVBOBA=; b=Baf9I8WpbcZi77h9WML9iqKMvsxo091YtTBHKnX5uB3bPAOZaa1V/EbT5Jm3T7FyxBAa3X0YVQkHRuugz4LHjWT/6c7+N0RcR2GIepwqrxn2OwxNr4pyP/yYRtWsIdOUmmxtOYUAEbqiCM4T2utKrQ5Z3jv6ipeIKKyZkaC7AMK7CJj0pW1MTnXy8OPvMXkxAF9u/ag0a5P/gqU1+ZHTTuUTL4sMhNM8BdpPi663COOOtazQ/yrjUtLS0akYQX7yABzXQWr2vmNyZejHDfH911EtXbAom4hTP+gHUtMDf3xU0/NKtccMsjP96+TSveE9qzP9Wfd+m7rQ2dQLvQeUlA== Received: from GV1P250MB0737.EURP250.PROD.OUTLOOK.COM (2603:10a6:150:8e::17) by AM8P250MB0137.EURP250.PROD.OUTLOOK.COM (2603:10a6:20b:320::11) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7409.24; Sat, 23 Mar 2024 02:06:36 +0000 Received: from GV1P250MB0737.EURP250.PROD.OUTLOOK.COM ([fe80::4a3b:cf76:cddc:c68d]) by GV1P250MB0737.EURP250.PROD.OUTLOOK.COM ([fe80::4a3b:cf76:cddc:c68d%4]) with mapi id 15.20.7386.025; Sat, 23 Mar 2024 02:06:36 +0000 From: Andreas Rheinhardt To: ffmpeg-devel@ffmpeg.org Date: Sat, 23 Mar 2024 03:06:14 +0100 Message-ID: X-Mailer: git-send-email 2.40.1 In-Reply-To: References: X-TMN: [3RmXZhbyjYuhhtyczKbMQIJx4uwpWOPI/QBPfYftHKY=] X-ClientProxiedBy: ZR0P278CA0005.CHEP278.PROD.OUTLOOK.COM (2603:10a6:910:16::15) To GV1P250MB0737.EURP250.PROD.OUTLOOK.COM (2603:10a6:150:8e::17) X-Microsoft-Original-Message-ID: <20240323020623.1570961-5-andreas.rheinhardt@outlook.com> MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: GV1P250MB0737:EE_|AM8P250MB0137:EE_ X-MS-Office365-Filtering-Correlation-Id: ff5a5b9f-46dd-4fc6-4e9f-08dc4addde8b X-MS-Exchange-SLBlob-MailProps: Cq7lScuPrnqkjmXb1vlddM5aSa/Epk3A5BtU9hmZ22jUkeflt1ZE4qWZsHCUKeKbkRSGrh4/xB07BNpx+K1kDf8klians7gCTFwGg19uyoNG+ayOe3Y4CKvgVaVQJFPWtZQ9OXIj8PzCTsfZgAxvmSCy04erx1ETGgXwa8vDCEzYMknWGo9bqqrrCK88cyDQH/GoIo161b9kqLEshjptLnTDePtJ+n/PZWGEgp71ff8r11eFDhlKN6NsyXOXqGVloKIYNGbV1VCD/EZcsY2I6z+i7qRPd2JOH5SaNPY6ySWPqPMjwn9TQ9zZ1Gltjkrmg6kfxwUs2vF7IBpI14mlCynVGGGpsj5n2Ctm9toYlLeT/ca1Hme/tI9Hg5th29m84jGB7GGZ2b/cRmUYBknmy8jLo8yNxitw9rXoivlfcvIyz455I5YAADZ7EX2Kee6J4EvGUrJGX7UBGbQOQThNhtHAVMb3mcPxrF63SRgRq/1BZ9VDchx2i2y9LWvHa/udVH20+SxxYzfiPQ+hwGarSqjOZuaNfXiQZrl30o4TsBX38M+I8C1b2lhV4t/8BC52DEBdXxAEpGlwqrRs0UX9TY5XL1cMDsJj9Eczc3vgsCrQzXHmLWF4eQItStlR+mU0K+YAG+jfQbuOzIz8n0Rfk5jvMViLvvKYalQMTu9L+lHHxfTCKhr5iSOSkwMfj3J/fwktzpFJKjCeYuHbcE7bQ4T1GaFL8XCRa+MwKWCW9U1Sh1CMIjlWzZov/qp8eVT0rhza1WBK/Ps= X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: xIa9tEFlu8dSDXxSCRWr2k/buiVjDfmsg2SD9J8OdZKelt5UTGh0mhKVcdHlSzDqs1TtiCA3TksDoJPJ76xu9WKmkDlBjPlVabxgTwluzlYE0DoZ8vrcU9YYu5OrjyS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1iuezupfmsgs+S6gqq8iqKJWxP234E+pBIPQ6XVqp3Pp9cfCv1789UZYzVPUQwAli9+pmgtk3m6EoTr3NSqzlFznWjASUvY51D/xbrBE0YPbFhJYLugsf++T/NKbp2jsU4PIRSxZScZdCpGD6S+YU25Sset+SJgn0IRW6uNE8mpm9CA/WbiSf5rM+fnZMHGwG49mo2QuhAqcOSvvJziLYfdUnhvanwHOCDeyjGi/OqNJUqiHnc3PmMG0nrVLIjtvly4FOiPK8wyTuEvwWvjeH99S9r5nhh0yMBevkSRgruVnYECbdOG8G5kMvIHaS78vZDE9i9ajSC5p4fyROhCpqfcfX3OsnJ0ibk3XcKi3vX4dseIJEfpDtSVaykyWbr3BjAta5bI+gzxrpvqzn3n7twI0fPl2U/zS8+X6yaFMMTPw9RbVxcFkVwHbDTL+orDQRtN/tP+T0FjLKid3IGLQ0FJZF7Qd7jaFw/6N2tK2g/fT41gUJQTZtZpk3tApQV8UlCE/rlQRo0NafqkdoSDoBzGNdQ5aE98h2mCTX7YoPWV1h1k8RacyNEXS2Gd1hsvHpCg/pORakwn+ynSAc8NYFzdQQWDC/MchLTv43vUBeZ3zJseHTX0A0X2l0EXkV4aeeaK9Xt/jWzD7fUsXPYOkkx2YpVdtgp4ZsdIL+yvgLCMXv5+UNdKku6d2L/Pb19dMO4CNkynjeVdYDYeRNlMy9ra2nmQN8SgY4gEyaHWvbPiuG7oUsXBjWE90lWm3DyuSqc8lEhF0HIa3QD2jVDn9t3hG2JuBDbxQ== X-OriginatorOrg: outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: ff5a5b9f-46dd-4fc6-4e9f-08dc4addde8b X-MS-Exchange-CrossTenant-AuthSource: GV1P250MB0737.EURP250.PROD.OUTLOOK.COM X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 23 Mar 2024 02:06:36.4274 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 84df9e7f-e9f6-40af-b435-aaaaaaaaaaaa X-MS-Exchange-CrossTenant-RMS-PersistedConsumerOrg: 00000000-0000-0000-0000-000000000000 X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM8P250MB0137 Subject: [FFmpeg-devel] [PATCH 06/15] avformat/fsb: Don't set data_offset manually 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 Cc: Andreas Rheinhardt Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" X-TUID: m4FEDC3fIA6N It is set generically to the value that it is to here. Signed-off-by: Andreas Rheinhardt --- libavformat/fsb.c | 1 - 1 file changed, 1 deletion(-) diff --git a/libavformat/fsb.c b/libavformat/fsb.c index 4189822d8e..0febeffd56 100644 --- a/libavformat/fsb.c +++ b/libavformat/fsb.c @@ -157,7 +157,6 @@ static int fsb_read_header(AVFormatContext *s) } avio_skip(pb, offset - avio_tell(pb)); - ffformatcontext(s)->data_offset = avio_tell(pb); avpriv_set_pts_info(st, 64, 1, par->sample_rate); From patchwork Sat Mar 23 02:06:15 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andreas Rheinhardt X-Patchwork-Id: 47360 Delivered-To: ffmpegpatchwork2@gmail.com Received: by 2002:a05:6a21:1014:b0:1a3:ac71:9534 with SMTP id nk20csp286194pzb; Fri, 22 Mar 2024 19:08:18 -0700 (PDT) X-Forwarded-Encrypted: i=2; AJvYcCVnwGOffTehA1IfSw/B0b5LZUayvO2j1PJyqrvqLwbAm0bi79ttfh8gFPaTgBKoqp6b3dX6JzSGlC16dvA+P/ZtzQhY+J9ptfCeZw== X-Google-Smtp-Source: AGHT+IHGoxgTdOKIHeIf9qU19iEDB10C31qWvxQcDAe244b1hZxG3uBFFP72F5tDgGbyptK7WjIb X-Received: by 2002:a17:906:1318:b0:a46:ad7c:50ad with SMTP id w24-20020a170906131800b00a46ad7c50admr799635ejb.3.1711159698501; Fri, 22 Mar 2024 19:08:18 -0700 (PDT) Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org. [79.124.17.100]) by mx.google.com with ESMTP id hh9-20020a170906a94900b00a46bd891b68si376823ejb.587.2024.03.22.19.08.18; Fri, 22 Mar 2024 19:08:18 -0700 (PDT) Received-SPF: pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) client-ip=79.124.17.100; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@outlook.com header.s=selector1 header.b=UwagemCC; arc=fail (body hash mismatch); spf=pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) smtp.mailfrom=ffmpeg-devel-bounces@ffmpeg.org; dmarc=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=outlook.com Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id A16D068D5EE; Sat, 23 Mar 2024 04:07:00 +0200 (EET) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from EUR04-HE1-obe.outbound.protection.outlook.com (mail-he1eur04olkn2090.outbound.protection.outlook.com [40.92.73.90]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id 94BB168D5DE for ; Sat, 23 Mar 2024 04:06:49 +0200 (EET) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=jQF9oP29QNRe/N3vhYn8JLEDfeprCV3TJDKftTAg0ax8AqjSyegMGzlBR+WcG+R1PgJQbP/1wM3yhIKtgt6J76oslFkchS3l2xB5G01Yeq4xW4DYJSDXnNg+13OIz48Xb76MOWDxrswThqqX9Z6Zuac5Tco/ejnJz926F+WGj46v5zysvdac1uru26Pj7wa7JOKmBVNWVZdwuGk2Vn5p2w/V0EXOsLPeZJn2gwtd0K15CUZkMjFdKBF8Kv0rdzY37Mta9i5vG61mR2V9Bp/VJiimlqSQborZs7f6OOZRkMTeFgnOMANWU44gbVctxFLxOfwKJKW+Ln02Rlj05u6lfQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=HM+1wN2Lm1acLPf5zAwp47upF4Xw0/BcxabH0OJuZQs=; b=fzF6ZqG4kVjXjSnQKt7+hqPRZz+EWvYfQSwNYCqb6VkD+xjh0fycmrHb+iNa8B4X08TE8dyCGAGG0NVCKnVS5r8xfgHfOdI2flhD5QoJBOrped4JGwg86H6wz6tuEZir3rcvQvsNWtejOir34kCcWMr42flv648Ffm3BbG/e3+Ps7mdaHr/C6wYLZD4z1+ifwO4hfliWoJ/nh9STqM5U7IxG0OjTRz91pRAcxBsx0GqxS/7O6ZIX+NeVf6PdppN3XA6UMG48En6IOT7QveGMb3BoBV1VYAm+xPCYksANQFSj0lIfuqcOwuC3pFHHbcLVKDjhMlRlF6KMJ+afoU/d+A== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=none; dmarc=none; dkim=none; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=outlook.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=HM+1wN2Lm1acLPf5zAwp47upF4Xw0/BcxabH0OJuZQs=; b=UwagemCCKlkQbnc2NV1JKoug+D5MauCKz8qgahtDLFeSvVIzsmZXXhIWbv3eZdp2gZua1t0shjKexs2O0/ZbnR2T7TGVwKJWbUl/pf06hLLCuPIBY+EHQzY6rkpQYSi8mDIAyEW3aRShq2Jo0PfES8auhUjHaHQOvaW4Rxg4V7W88AS1wu+MRPJLVQQIRJGQD2Vks6j0Uh/OhzGf7LkFUnzSl86Xvtsg4ixpIRVF4SIiYTaMZ6A5BQNgGp//sVZV7VjwqB2w/F/K8n1quizmifwMVfBqtzi51y4oHqfPWz2hnbfO7wA0w3h1tU3BzysAa5HLj1kQ4DMhXFsrxwKfmA== Received: from GV1P250MB0737.EURP250.PROD.OUTLOOK.COM (2603:10a6:150:8e::17) by AM8P250MB0137.EURP250.PROD.OUTLOOK.COM (2603:10a6:20b:320::11) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7409.24; Sat, 23 Mar 2024 02:06:37 +0000 Received: from GV1P250MB0737.EURP250.PROD.OUTLOOK.COM ([fe80::4a3b:cf76:cddc:c68d]) by GV1P250MB0737.EURP250.PROD.OUTLOOK.COM ([fe80::4a3b:cf76:cddc:c68d%4]) with mapi id 15.20.7386.025; Sat, 23 Mar 2024 02:06:37 +0000 From: Andreas Rheinhardt To: ffmpeg-devel@ffmpeg.org Date: Sat, 23 Mar 2024 03:06:15 +0100 Message-ID: X-Mailer: git-send-email 2.40.1 In-Reply-To: References: X-TMN: [LkPib0MDLpj0fqSguYKqGGMK/hWtPzybLjpMOGazV0M=] X-ClientProxiedBy: ZR0P278CA0005.CHEP278.PROD.OUTLOOK.COM (2603:10a6:910:16::15) To GV1P250MB0737.EURP250.PROD.OUTLOOK.COM (2603:10a6:150:8e::17) X-Microsoft-Original-Message-ID: <20240323020623.1570961-6-andreas.rheinhardt@outlook.com> MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: GV1P250MB0737:EE_|AM8P250MB0137:EE_ X-MS-Office365-Filtering-Correlation-Id: 69e3dc33-630e-429d-e55a-08dc4adddf4e X-MS-Exchange-SLBlob-MailProps: 9IecXKUgicBMjzDtAlr46x5HKEJiZ0RbaTHljGk6gn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MID5l/xo8srM9j/0t2Bxyuu2+sUckaIeF/sy8nO8AnCYUyTEHQABTsRqIDwTbfAMmGKmpgDDSFCOWpeRY7YBI3WqTp/lQHLFgMDtk/9w0iph2v9m8wGFIPF8lLWjugEyIIq1UEs33Y9nkEIEALdQzWytv/lnJajPbtsyK3u4hHUybRhVoE8q+NoC1ORSwXxX5KYdsMlBbpedXJy4esXq/94FE9XqGSTrDeBF0pjTBloXaSEhRqUtKpGyrLUIYlKWqqL0bchkqm81blAgyn8AnHvZgn0zK+CJoIP7baApZ2bVCv0fyogbnWkyJp1tLIvdD8lwZbL1KPL2eGBzKwwCMxA2kCW/bYc36ZcvX2i+hJ5AgSqkHr0xkE3XWKTd6VKZzLSWjyXE/Gsd2qIDhGJi1zJczEi/WdY5hhwqQIBJ0W+6hOfpmJEYzoM59VNnd9uCS5hDtMjk8dSSMePFt02uPafifoPyvYLag00e8BuVp/intk6acsZM/1udC1TMxC8SkSiJb1OxC5XKBgXkAxRS5f0eJsvmRaLCLb0E4wjWfQWITTpsBz68oBVLAkLDq7X8lJJTL1FhmePjfyOk1SL1pLqKUukQ== X-OriginatorOrg: outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: 69e3dc33-630e-429d-e55a-08dc4adddf4e X-MS-Exchange-CrossTenant-AuthSource: GV1P250MB0737.EURP250.PROD.OUTLOOK.COM X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 23 Mar 2024 02:06:37.7096 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 84df9e7f-e9f6-40af-b435-aaaaaaaaaaaa X-MS-Exchange-CrossTenant-RMS-PersistedConsumerOrg: 00000000-0000-0000-0000-000000000000 X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM8P250MB0137 Subject: [FFmpeg-devel] [PATCH 07/15] avformat/avr: Combine skips 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 Cc: Andreas Rheinhardt Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" X-TUID: VkFiUxQwyJWz Signed-off-by: Andreas Rheinhardt --- libavformat/avr.c | 12 +++--------- 1 file changed, 3 insertions(+), 9 deletions(-) diff --git a/libavformat/avr.c b/libavformat/avr.c index 12286c04d4..261edef4b5 100644 --- a/libavformat/avr.c +++ b/libavformat/avr.c @@ -49,8 +49,7 @@ static int avr_read_header(AVFormatContext *s) st->codecpar->codec_type = AVMEDIA_TYPE_AUDIO; - avio_skip(s->pb, 4); // magic - avio_skip(s->pb, 8); // sample_name + avio_skip(s->pb, 4 /* magic */ + 8 /* sample_name */); chan = avio_rb16(s->pb); if (!chan) { @@ -66,18 +65,13 @@ static int avr_read_header(AVFormatContext *s) sign = avio_rb16(s->pb); - avio_skip(s->pb, 2); // loop - avio_skip(s->pb, 2); // midi - avio_skip(s->pb, 1); // replay speed + avio_skip(s->pb, 2 /* loop */ + 2 /* midi */ + 1 /* replay speed */); st->codecpar->sample_rate = avio_rb24(s->pb); if (st->codecpar->sample_rate == 0) return AVERROR_INVALIDDATA; - avio_skip(s->pb, 4 * 3); - avio_skip(s->pb, 2 * 3); - avio_skip(s->pb, 20); - avio_skip(s->pb, 64); + avio_skip(s->pb, 4 * 3 + 2 * 3 + 20 + 64); st->codecpar->codec_id = ff_get_pcm_codec_id(bps, 0, 1, sign); if (st->codecpar->codec_id == AV_CODEC_ID_NONE) { From patchwork Sat Mar 23 02:06:16 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andreas Rheinhardt X-Patchwork-Id: 47355 Delivered-To: ffmpegpatchwork2@gmail.com Received: by 2002:a05:6a21:1014:b0:1a3:ac71:9534 with SMTP id nk20csp285950pzb; Fri, 22 Mar 2024 19:07:27 -0700 (PDT) X-Forwarded-Encrypted: i=2; AJvYcCWwNJDU1zhef5B8MRbEbIt6AmqYXylFlg0gy7ltx9QenVYpKpUbhF86tU5/cS1JqPG7XiUr69swPtcvx8dEHrC/O+1DREOTEHTcjw== X-Google-Smtp-Source: AGHT+IFXN+Lz/UgffRbKNiZL3w7V9AlIuLIvjM3slX+uwSCGV6DRqnbk23QZpZ+FkTy+eJVNWi5i X-Received: by 2002:a50:bb0c:0:b0:56b:eb92:3d with SMTP id y12-20020a50bb0c000000b0056beb92003dmr641171ede.3.1711159647133; Fri, 22 Mar 2024 19:07:27 -0700 (PDT) Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org. [79.124.17.100]) by mx.google.com with ESMTP id q4-20020a056402248400b005689f540351si399849eda.140.2024.03.22.19.07.26; Fri, 22 Mar 2024 19:07:27 -0700 (PDT) Received-SPF: pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) client-ip=79.124.17.100; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@outlook.com header.s=selector1 header.b="YNZp/j7l"; arc=fail (body hash mismatch); spf=pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) smtp.mailfrom=ffmpeg-devel-bounces@ffmpeg.org; dmarc=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=outlook.com Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id 580AB68D5F1; Sat, 23 Mar 2024 04:06:55 +0200 (EET) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from EUR04-DB3-obe.outbound.protection.outlook.com (mail-db3eur04olkn2050.outbound.protection.outlook.com [40.92.74.50]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id 9602168D5CB for ; Sat, 23 Mar 2024 04:06:53 +0200 (EET) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=A8QFIw7R8d7cCxqQ6xzn8UhPjXIJ08rLgUfVVdtGZDNx3AUzwaK6YngG7BxQw04CynedONVIFcg1IAMEZXpF9dgraqGKrumaVCXwSn0KgtjCNc7nfMYrPn6E09yL9XDHyVmWZdIOr22qszaNlikYjFhqIwmlHYVcmFXKc4TdGRb2EodN22HIq+FpBMtesMKU/ku5FXCTW/vxwdynO9Gpr1xD0t5I4ELgnzqHT+8pw9qpLBeRMWwA/KJiAPc/KzKknjMvLzPjfBWTt7c3Z4CvdU7FzJblaF+ONgBLP8k5gpxZVZEr6j8FemNEKBtG0CPCWgHog0SeiovOQ3UNXkLZ7Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=NLlufkZ92CQEM+oXOUG9ELpL6OjGUDNPCTt7XVd2Wxs=; b=XACB43z+Iu4WL3r9oMbNA2lyh7YMtXr6VRJL6CgpZlQVoB/hW8URKOZeUok7mLRzesZK0RCb8GQRZduA1nTEQwMr0R8+GShB0qQEG5ycZOLq8rdrK8kcezzqXejub9yh0xUMZwTKY5+spGhrRvVZL9FiP5omjGgJ46yTDKV8lHq47KkJzq6rzDvoUjcrSUGgAYl7eOIwA5p3DkfCNLHKMUIrW9BwLUq/5eshtp6K77FUkuQ0HdkGBBpaSBGyBTAxVB5M8b5JeObojvg2cjY87Clgft5vQtN3fXWG3RrB3n3Bzn/3rn8EfIAwe5X4RPDGMJy3DE4oWemYdQQCdsYztw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=none; dmarc=none; dkim=none; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=outlook.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=NLlufkZ92CQEM+oXOUG9ELpL6OjGUDNPCTt7XVd2Wxs=; b=YNZp/j7lLXYRBUN6JeWQ8lLHlQZDfU5LjDO+uHgRiLcIw6afvfRnpp281nCjwTLWI8C40+OGCTl96nPSQECoYhQ/pPENeXDg+ROkuhjRdzOu9vAVdLd7yc9G4vXbSMRXOr8q8EqqHPqcYpKjPdlyWasmbbDA3Hnx7BrKQL3FEcFgC77kGaNThOHCdbCW1MGdBFW37k56+08Nh9wcX+aZ+tAm9aOJ5WueReCMQGZV276AhN0oYcXrBreLiy4BExsAHvXi+1mbDhPxfOaA8kD9DDTqsffHQeJDqAnl8Dho8qpyxvlzs8/Gp9OhohxXWI4J+DeoIy9XCOSOA0ZDnkJ++w== Received: from GV1P250MB0737.EURP250.PROD.OUTLOOK.COM (2603:10a6:150:8e::17) by AM8P250MB0137.EURP250.PROD.OUTLOOK.COM (2603:10a6:20b:320::11) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7409.24; Sat, 23 Mar 2024 02:06:39 +0000 Received: from GV1P250MB0737.EURP250.PROD.OUTLOOK.COM ([fe80::4a3b:cf76:cddc:c68d]) by GV1P250MB0737.EURP250.PROD.OUTLOOK.COM ([fe80::4a3b:cf76:cddc:c68d%4]) with mapi id 15.20.7386.025; Sat, 23 Mar 2024 02:06:39 +0000 From: Andreas Rheinhardt To: ffmpeg-devel@ffmpeg.org Date: Sat, 23 Mar 2024 03:06:16 +0100 Message-ID: X-Mailer: git-send-email 2.40.1 In-Reply-To: References: X-TMN: [FfnI7q59yTLZZuOX7dIrUViOrZiL5fKqPkWRy4WQAMk=] X-ClientProxiedBy: ZR0P278CA0005.CHEP278.PROD.OUTLOOK.COM (2603:10a6:910:16::15) To GV1P250MB0737.EURP250.PROD.OUTLOOK.COM (2603:10a6:150:8e::17) X-Microsoft-Original-Message-ID: <20240323020623.1570961-7-andreas.rheinhardt@outlook.com> MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: GV1P250MB0737:EE_|AM8P250MB0137:EE_ X-MS-Office365-Filtering-Correlation-Id: e89a5a9e-2473-4bbf-41fa-08dc4adde036 X-MS-Exchange-SLBlob-MailProps: Cq7lScuPrnqkjmXb1vlddM5aSa/Epk3A0iv0vEUyLYw3CKWHzxECklSRfqpaV1vB3YAbcMP+CU7co8v+Skn2DSW2w2aYWNh6O0Dxs6ABzvT/AFsa2JhcwSOdrrLrA0f4A8v7GQ96+WbBJ4FUPfCba8oN3Pp76nJSK4KApnwSiTdf8c/nP3zDojJgqUBMqxDtmizCvbYUGDfJWafnTPTLV3KApnkMN4oBhfedIX8XsVwKGmqSaWVfx+ekU4sXTujh3qgmUC77cORvbc+0S21KeG3XqpZTuz/xxFDOoLcDXwXs/SGcWqitrDAbkdmP0yomAC3IK2qGJcbNf9R5zdVjYd7fL4WHtCqXjLB/xBukIcZm73ZDowEN1HHLibkTR22GJRIatgcOW3iEwyH7gEr/kCJrEPSZu/M5w45vGtBziApgAGXe3EeMazHrXYMDHNPNG7ZuIwb1AAY/mDm4kob9XCUZX/zk82ILW59hrhp9hJBbZ5yN1FTSLiZvtcA3pvGuG3xP9RptewIZ+qKxTCw5LT1PLKlwZ0+0to641CfghwH7rqLT8/dJR2eHltWtoDWRw3EhPEJKP7swB6xlkO8saphT+gmU+PscuUAqxohp3T76geJn4+Y6dPMU12bLtWz/ueaOTEx7UrhOR3YrQDaVBWsOKR+Ij/iKXwuKog66E13a5BhqWXm0qn6qU9cZUuu5JmMpS+6bDiXJponaJ4ZVsDCn+dzdvePvoMAuU1vFY+1gQDAolB+ENSjo6dY2TQ+Y/bzXDDR2RDs= X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: AljAu7h4LRFxCahyywoU8WAjNHvTrUsuqG0bWo+ZfBjtYl8I/A0n6aInD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r40A9gKQUecIBKfp9EiNiwxnnsgv9uXGgtNmNMheSeLYtNqkOZiNjl42etRIf7xLWNgOmDs1ch42tiITqdLSi0EeEGqtrbhIrB6ZTMmOSw98HZKtvzozwoPCW925uEsy8WisCiKHM6I7YQ7/Ge9BQyaWXFPL4lA73kWlWZJVZF8UWjAYd2O6YsnQ1C6hnNLX9on5nx0zAKSACliqmH8BzP5rYvhf9RjJe9lbFY9QStPLJIKNRhg+DAWtXmuE94FfR6gwf5gAxQwMniwYK89U3dmp94YImhm3+yfM2PYjhKx+k+tp3S8PU+tVNGzSfWseK/byopseW/zoFZx8Brl5bxv7PPIozJ95IF0xRgAG+6qWeE2chkzD5QuGNytq3nHZvELH8Bd2mxhqjEvtnGeoQCwKqPG15RPlkRW0HGWNf+H+CXKCmKVaf7Sloys/zMi/Ak8ZnFfmJxawuEczvobudav/6bZZc4fBfsLPXd4XW+7jVeYkqc94oAPXdnJEaJX+Lanj0H35DUBrG/2x1IwSjnDdRGriaBEi4AWZc5Lok7AsG91JKyaXV5lrG0n60sKf2Nv3JvP+i73QiXIw9ZiBh5/kxGQFGZ4ocCyo3Evpk8tinS8HwWmcGJbH34y3921isGrAQPMTjs+tBuJyLzZubJD5FQ0N4qIVN3xMGeAQVp3Z2Z2d2tL213jnAYbd1gdeJgmfS1XvOCuQjoXAc6XXf6ieCc3xnzcTaikDISAjjs9PUjPhR0HYJKBMeXysqOKmn5e2cIUF2j3Ylg+fOo78ZHFOGxDsd6Kgjcnf6DBOw4QoBMhfz3/2ai0eM5IVtiinIi70/4KuA== X-OriginatorOrg: outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: e89a5a9e-2473-4bbf-41fa-08dc4adde036 X-MS-Exchange-CrossTenant-AuthSource: GV1P250MB0737.EURP250.PROD.OUTLOOK.COM X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 23 Mar 2024 02:06:39.2053 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 84df9e7f-e9f6-40af-b435-aaaaaaaaaaaa X-MS-Exchange-CrossTenant-RMS-PersistedConsumerOrg: 00000000-0000-0000-0000-000000000000 X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM8P250MB0137 Subject: [FFmpeg-devel] [PATCH 08/15] avformat/wady: Combine skips 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 Cc: Andreas Rheinhardt Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" X-TUID: 90fdOMjK7EHt Signed-off-by: Andreas Rheinhardt --- libavformat/wady.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/libavformat/wady.c b/libavformat/wady.c index 6dcc0018f3..17b7a88c19 100644 --- a/libavformat/wady.c +++ b/libavformat/wady.c @@ -45,13 +45,12 @@ static int wady_read_header(AVFormatContext *s) int channels, ret; AVStream *st; - avio_skip(pb, 4); + avio_skip(pb, 4 + 1); st = avformat_new_stream(s, NULL); if (!st) return AVERROR(ENOMEM); - avio_skip(pb, 1); par = st->codecpar; par->codec_type = AVMEDIA_TYPE_AUDIO; par->codec_id = AV_CODEC_ID_WADY_DPCM; From patchwork Sat Mar 23 02:06:17 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andreas Rheinhardt X-Patchwork-Id: 47348 Delivered-To: ffmpegpatchwork2@gmail.com Received: by 2002:a05:6a21:1014:b0:1a3:ac71:9534 with SMTP id nk20csp285998pzb; Fri, 22 Mar 2024 19:07:36 -0700 (PDT) X-Forwarded-Encrypted: i=2; AJvYcCVX/ZdxUL3Dsr5HGwDjLZZnRzuMRr5pduOOKeOYUmiAKFROGq04HecO/nh+gSO5MRX3LceqHzWY8XXUTmnzB6xSC/FvOxDR8TL1sw== X-Google-Smtp-Source: AGHT+IFuYE+uwewu2RZQCje/6y3g0CpRY5hmxUECk19hJI6fIar7EdUeI1sbyVHyTrsCcUDb3CjK X-Received: by 2002:a17:906:6b0b:b0:a47:14e0:50d2 with SMTP id q11-20020a1709066b0b00b00a4714e050d2mr863614ejr.3.1711159655854; Fri, 22 Mar 2024 19:07:35 -0700 (PDT) Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org. [79.124.17.100]) by mx.google.com with ESMTP id r20-20020a170906365400b00a46dfbbe649si385506ejb.272.2024.03.22.19.07.35; Fri, 22 Mar 2024 19:07:35 -0700 (PDT) Received-SPF: pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) client-ip=79.124.17.100; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@outlook.com header.s=selector1 header.b=PFIApeYi; arc=fail (body hash mismatch); spf=pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) smtp.mailfrom=ffmpeg-devel-bounces@ffmpeg.org; dmarc=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=outlook.com Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id 25DA968D5F9; Sat, 23 Mar 2024 04:06:56 +0200 (EET) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from EUR04-DB3-obe.outbound.protection.outlook.com (mail-db3eur04olkn2050.outbound.protection.outlook.com [40.92.74.50]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id BDA8768D5C9 for ; Sat, 23 Mar 2024 04:06:53 +0200 (EET) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=RYVvA8U8sn2ALT9QIwNmBEuLMeYpHnOGWflTcNwmFr1E27FkfND5QpuGr4/pxl+MhjVp1RE1VCQRBMqyPfUZP45rELxLVy22gFmsH9eCn/xh9a/Jtuz4B45QNG0T5ODcMQGF8rYZU24/KCKKD/MPllq/+/SsstyHiw3GSoRl+Gb8h/H7cb+1NUzbHaQO/MI0O5EMlEluISPUdq3kWJZO0Mnv8K+CgT7ne20UH7LYcz46iG4cM20xCX2C6k9+FtQ3W6yeO7QU20zBy20h3HnxTgMHd5wiRpoUJG8xyBFqylMVcJ38TqAZH/BZQVWRFv8lVDsGFMx3ETvuaLZ0p4rBoA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=bQsONzj8cSscyZevlkKpRMkjsCFDPmzigQlv0F96nQI=; b=HJQvblR1MPqp5Xu5BmW5AusIP5JiG0SGFtzErp5YcT3vVJHjqij9UhnNyC5qedFtvXNib6CznRfURGIRMo7u6mb8UimSV1xlglx6HWFOJnHkm3g+au+VHTd4gd4TsXndmakrYLkS2Gvr/xA0gXn5C5bRzZ/BAMET/XSeHleouAlEJTVK1C5xqV8M9IV4IiTv7iRdRNrd/rMvXFFePO/4bMZDZOB8OsOCob6R1uElGIJpZEee9JprIhsJt37ZT3L+JB2sLYxlHDh8jfD3EgYnaGoUX5RmfsKab4/s6/qCUKZPa9fjQWR8VzNrDv14Q7JhP83iNDxdx34KEIuprOWveQ== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=none; dmarc=none; dkim=none; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=outlook.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=bQsONzj8cSscyZevlkKpRMkjsCFDPmzigQlv0F96nQI=; b=PFIApeYiPSVGdnA5rXXxvdfwxN3WQv4/eim1/jSSqEInFfqDyKCJHUsz/17C3CZQKzyrwcg1kbP358g9w5hovXpCnrIFI+O7vJQf4zqac7PoT3ytsno4Tj/loJahFaJkJ4a8co+mYmerpgkiBMkaGyGfNNlr8kC1AXydXQ2y2U2jk+V3Wtz2p7zi7ChdpisgsXenp8AjDKBsQWY/eFGwQFhVlcJHqR9kcNh7uyapP9RkvZX5S8BHX0Gj0GgnWfiI/NSZ6hcszdIXi0beeCym4ceU4hDmIfBI92F/4po+Km0kMRSuG0rB+M6OPkj3v+3MIhKwBbR8FaYWoGI0Bp7/Xg== Received: from GV1P250MB0737.EURP250.PROD.OUTLOOK.COM (2603:10a6:150:8e::17) by AM8P250MB0137.EURP250.PROD.OUTLOOK.COM (2603:10a6:20b:320::11) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7409.24; Sat, 23 Mar 2024 02:06:40 +0000 Received: from GV1P250MB0737.EURP250.PROD.OUTLOOK.COM ([fe80::4a3b:cf76:cddc:c68d]) by GV1P250MB0737.EURP250.PROD.OUTLOOK.COM ([fe80::4a3b:cf76:cddc:c68d%4]) with mapi id 15.20.7386.025; Sat, 23 Mar 2024 02:06:40 +0000 From: Andreas Rheinhardt To: ffmpeg-devel@ffmpeg.org Date: Sat, 23 Mar 2024 03:06:17 +0100 Message-ID: X-Mailer: git-send-email 2.40.1 In-Reply-To: References: X-TMN: [YRII/D43XXcYX54eKfFj3wBZ12fVqNC7ktHHukqrsds=] X-ClientProxiedBy: ZR0P278CA0005.CHEP278.PROD.OUTLOOK.COM (2603:10a6:910:16::15) To GV1P250MB0737.EURP250.PROD.OUTLOOK.COM (2603:10a6:150:8e::17) X-Microsoft-Original-Message-ID: <20240323020623.1570961-8-andreas.rheinhardt@outlook.com> MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: GV1P250MB0737:EE_|AM8P250MB0137:EE_ X-MS-Office365-Filtering-Correlation-Id: 7fba14e8-5fdb-42a2-da21-08dc4adde0e9 X-MS-Exchange-SLBlob-MailProps: Cq7lScuPrnqkjmXb1vlddM5aSa/Epk3AS3pGvEfQnJuROrbZZQ4oP89ROaTAofPVr8tklBmLqmncw86TqBr1C0UvGfF+iOgj5TzMRYSICc7f4bx1gpcHhFMLVXr3+x5CmNgX+6sHHJg7Dintc4kwwwI+lo1EQFy2Sr8VtuHzM8AZBGSD+mg04phIK/G+W+bvjbkCYVJPmnH/sqUqGbJQlnm+P3H2JEdXLD+3tGlZ3fJnJROOJ9VTF+jpO8uyisJ/wfjZIli8pKbIkZ+O/1Ucoh+rc1utrPj5Hv4Azf45QvUmSxEVXTELNN+X5+vD+s3V7HZta7AqUkL0aaMFaCg0G+gliwkqHxW84Mul97ZM6yoYgk+OqmFouHojfcPS8M8N1PJ9ESo0XcBpr8wVDNRJ9NS5moHwzhRbbNywol/Axe8sBQ2/wb3V5tBwy3T1R3mhI85Ig8eBnlGFp6biEDC8mSOhF7a/8F913e/Vu4l1Skz1wH94FI9ME5SYBcI6hJPfTp2x2vC+uzYsMojaqvJmSYjSaEu0sbSvTKCaEQ/lVVRxOUykyWO5G4SC7Ld1YKVdCmGDOMUdoicyusSHhfTBdQy0Kq6qczi1CHJv76h+j4PjU7RbDikctvDd8ymYpcxpaEPCsgTNdpdpEK24bQ+/QWdcrA4b8Av8c1eNvgp3TxqdMnPh9jjhy4Q8FWohlArxV728OJxYlqrwbp9hRraF4M9PFWasxiLcIE4UZ/Va6G0GK4WgGITbyLPX3DK6iLqAKoR/TnVk2oc= X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: JquE1zfXU2d98I5mB3Aobj8636ByM8XtgCmemVf7I9YnRMbwd7JI7x99hVsBn23R1qvoMz887bGFtwE1aY92Br0I3riLY0bfIQquTRnDD0AoDDAxTgJBErxjwxJSFfbjkbH72HlbJnA68kuxcgM3+meLRt93ITkDhkorvDQyMx/b3VaDdkn2s0CZEE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VpLTry+7BaOL++8lQGSreSCvc6P7P4riCyhrvsavywU3M43/exThisFNhmPp8bgbg1s/OyP+lXAJm5UfPBiYBfbAfYjktRoL08rH3L2FG6luzgWIrFNNq0b/Cn4C5IiCG/DPojWttkLpE/uNCvLf7FSfIelnd+62KhYqjXsvWrAhD+mtiJYGCW+yrgmDJ0L9ZW1rjsixVshY6I9fRKz+q8ww8MMnv/Z27ZFt21zXJG/fR5Tn2dDQhb6hW6tGbYVzk6qm90laRGei/7Xp4wWcqLFAP+xQBjtKVz42kVeltTUdLZ5wpAkM6CMeH0qOnz1Mm98BsUEE2sh2Y/s+Dc3G23PBcrO5MN18ZHebIdqlUk1EdD8xKMiQZeF7Nc/dct7BaQ88v8gVjWBbEERT+KG7bEQy09rawjEihoaG8FDZdKgrAYs/L6W4RfKs3BVvPtjqrZKn/cdDFmrsCxvX3TfaeIdM7rVBv8WalzEQbYXzmDCEwrk4xyEkEj3k/LKpkXoqAgZNquZNuB6R0nrH1TmD/AvCMTI+Tbo1BpwmRCLV2mEIOqFWh79YvCitGL3ABxF1z9Xip0e3OeIdockEKdMNJ22I3RczwukVgIVTc5KbIJAvD1XZtsnO10uhjAyXgSOaQqlYXNP+8J7SQZEPY9IpKdM58+jGo3qldTBgIiWx0pMfYdKyx959N/gjWY7BYKFfFphjA== X-OriginatorOrg: outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: 7fba14e8-5fdb-42a2-da21-08dc4adde0e9 X-MS-Exchange-CrossTenant-AuthSource: GV1P250MB0737.EURP250.PROD.OUTLOOK.COM X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 23 Mar 2024 02:06:40.3741 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 84df9e7f-e9f6-40af-b435-aaaaaaaaaaaa X-MS-Exchange-CrossTenant-RMS-PersistedConsumerOrg: 00000000-0000-0000-0000-000000000000 X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM8P250MB0137 Subject: [FFmpeg-devel] [PATCH 09/15] avformat/argo_cvg: Avoid relocations for ArgoCVGOverride 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 Cc: Andreas Rheinhardt Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" X-TUID: EiMuWEJLnbhJ The average length of the strings used here does not differ much from the length of the longest string; therefore it makes sense to use an array big enough for the longest string and not a pointer to a string. This also moves this array into .rodata (from .data.rel.ro). Signed-off-by: Andreas Rheinhardt --- libavformat/argo_cvg.c | 38 ++++++++++++++++++++++++++------------ 1 file changed, 26 insertions(+), 12 deletions(-) diff --git a/libavformat/argo_cvg.c b/libavformat/argo_cvg.c index 5db2a85dd8..03ae6fa59e 100644 --- a/libavformat/argo_cvg.c +++ b/libavformat/argo_cvg.c @@ -47,13 +47,6 @@ typedef struct ArgoCVGHeader { uint32_t reverb; /*< Reverb flag. */ } ArgoCVGHeader; -typedef struct ArgoCVGOverride { - const char *name; - ArgoCVGHeader header; - uint32_t checksum; - int sample_rate; -} ArgoCVGOverride; - typedef struct ArgoCVGDemuxContext { ArgoCVGHeader header; uint32_t checksum; @@ -72,12 +65,33 @@ typedef struct ArgoCVGMuxContext { #if CONFIG_ARGO_CVG_DEMUXER /* "Special" files that are played at a different rate. */ +// FILE(NAME, SIZE, LOOP, REVERB, CHECKSUM, SAMPLE_RATE) +#define OVERRIDE_FILES(FILE) \ + FILE(CRYS, 23592, 0, 1, 2495499, 88200) /* Beta */ \ + FILE(REDCRY88, 38280, 0, 1, 4134848, 88200) /* Beta */ \ + FILE(DANLOOP1, 54744, 1, 0, 5684641, 37800) /* Beta */ \ + FILE(PICKUP88, 12904, 0, 1, 1348091, 48000) /* Beta */ \ + FILE(SELECT1, 5080, 0, 1, 549987, 44100) /* Beta */ \ + +#define MAX_FILENAME_SIZE(NAME, SIZE, LOOP, REVERB, CHECKSUM, SAMPLE_RATE) \ + MAX_SIZE_BEFORE_ ## NAME, \ + MAX_SIZE_UNTIL_ ## NAME ## _MINUS1 = FFMAX(sizeof(#NAME ".CVG"), MAX_SIZE_BEFORE_ ## NAME) - 1, +enum { + OVERRIDE_FILES(MAX_FILENAME_SIZE) + MAX_OVERRIDE_FILENAME_SIZE +}; + +typedef struct ArgoCVGOverride { + const char name[MAX_OVERRIDE_FILENAME_SIZE]; + ArgoCVGHeader header; + uint32_t checksum; + int sample_rate; +} ArgoCVGOverride; + +#define FILE(NAME, SIZE, LOOP, REVERB, CHECKSUM, SAMPLE_RATE) \ + { #NAME ".CVG", { SIZE, LOOP, REVERB }, CHECKSUM, SAMPLE_RATE }, static const ArgoCVGOverride overrides[] = { - { "CRYS.CVG", { 23592, 0, 1 }, 2495499, 88200 }, /* Beta */ - { "REDCRY88.CVG", { 38280, 0, 1 }, 4134848, 88200 }, /* Beta */ - { "DANLOOP1.CVG", { 54744, 1, 0 }, 5684641, 37800 }, /* Beta */ - { "PICKUP88.CVG", { 12904, 0, 1 }, 1348091, 48000 }, /* Beta */ - { "SELECT1.CVG", { 5080, 0, 1 }, 549987, 44100 }, /* Beta */ + OVERRIDE_FILES(FILE) }; static int argo_cvg_probe(const AVProbeData *p) From patchwork Sat Mar 23 02:06:18 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andreas Rheinhardt X-Patchwork-Id: 47356 Delivered-To: ffmpegpatchwork2@gmail.com Received: by 2002:a05:6a21:1014:b0:1a3:ac71:9534 with SMTP id nk20csp286026pzb; Fri, 22 Mar 2024 19:07:45 -0700 (PDT) X-Forwarded-Encrypted: i=2; AJvYcCXodk77HaqJ/brMjOmUsqoIT8l8MxR2J1+v3RBjyT0IoZXrWBDNGhWtYCLgnrHC/jw/K11BPhfPSxUWdmG/dNQP/4SanzNi8AmS+w== X-Google-Smtp-Source: AGHT+IHqrAE6E8/ZK4iv28dbM1hvge3y+KuEmyDqr5lrcVo6PxgU+urtDMEwtRUYzy9YLCvT6W0L X-Received: by 2002:a17:906:e247:b0:a47:39d1:5dd4 with SMTP id gq7-20020a170906e24700b00a4739d15dd4mr931882ejb.8.1711159664552; Fri, 22 Mar 2024 19:07:44 -0700 (PDT) Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org. [79.124.17.100]) by mx.google.com with ESMTP id m13-20020a170906234d00b00a46d5a8294esi375521eja.156.2024.03.22.19.07.44; Fri, 22 Mar 2024 19:07:44 -0700 (PDT) Received-SPF: pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) client-ip=79.124.17.100; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@outlook.com header.s=selector1 header.b=ImtSde9A; arc=fail (body hash mismatch); spf=pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) smtp.mailfrom=ffmpeg-devel-bounces@ffmpeg.org; dmarc=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=outlook.com Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id E6B9768D55C; Sat, 23 Mar 2024 04:06:56 +0200 (EET) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from EUR04-DB3-obe.outbound.protection.outlook.com (mail-db3eur04olkn2050.outbound.protection.outlook.com [40.92.74.50]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id E390368D5D9 for ; Sat, 23 Mar 2024 04:06:53 +0200 (EET) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=l4bkHl7jhzBsioZhHS0d5Mo63m8aia85+1B2U0rJf+5dog6zzd07mnYq1JDhUMrnh6MdWDKWIy93ZTMcwTSQzvkmfo5+ltB63IMFU1njipsLPvSvgH9W8HI4zLp6gQdKPbUctVzFphEJq6ezGIBxxr6LqAlXW47hPmXnu1CSM8b92e9T1hGv+UYQ9NCh7p87r7gmeI+6xPaA+AzXHuiIKnVkuSsy5+tnzuLguDgRuhPQk5upNYGGEvAs+Zgpi3ZL4ez5awsqUXUV2DTJsF/IGqKjT52J2W3lqXltnJ+3KYQatjwP6Z0hr7sA15F4NUjcL6jaetPldaazUfnMOpFUhw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=prNXcqvz6RERXmTBjXA1Z4FVI2zLBNTot8zJBn2mM+A=; b=ZKTh0ClnNFluvsjl4XB7PzTzw1QiF+pi4S+d9/kGKTSNs2h/lXbhX+sKYEz5HLDZBdbh3YHPh7qhZ3k04HDj/SuSQM+Za+OP8jbNtVBmRY+pCIdXql3N5KglFNUjmRAWd9rBLIyZdOPmlXXorqWeiQNc84sYK573Ny8yDFEM8T28VJ6D/X19iGC0Jxxr911ILEYmxKz2nD3BtVTyuOtEeCMXcyuSnXx/5aPVmAgXRy8uWByOeK1bplWuyFCcE3ydQCDo+ABwWe0MiEXRcZhgxCzGcXG3FOW4SQPUX0oWJo1io/yXcS+OX51L7kM+eP2AkxGKMlLkKlrKeAP9Gxshsw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=none; dmarc=none; dkim=none; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=outlook.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=prNXcqvz6RERXmTBjXA1Z4FVI2zLBNTot8zJBn2mM+A=; b=ImtSde9Acps3T/7dwQDtsDNOLo0RNDdSgtd4vCucMTFZwppBPJQrhsTFT8a9Pgv6HuVk/9RX8lWXtHZFAsWtLQIHbdS0B3SEiA62gUbaIB9fGqzE/PDTBGOdGXRBu+M+bNaj7BIOnwN7QFq8xyfKfESEq9cP3kNu0cRezRinxAHbxFEreGYkGfCfWkqGrq6SBPdYranyLeF0wT0sBZB7YtEWFk0gzSRPtZdR9RcCCiwMXUSvPHSxx07fJtnJMqEHEA0PjQAkY+4uBDw5b3HuQuVjL7k+NegaFK62vUjtzgt4FoJdd6sRY6Ql2OaesP+kmvQS3bBkfz4KLyGRhm22bQ== Received: from GV1P250MB0737.EURP250.PROD.OUTLOOK.COM (2603:10a6:150:8e::17) by AM8P250MB0137.EURP250.PROD.OUTLOOK.COM (2603:10a6:20b:320::11) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7409.24; Sat, 23 Mar 2024 02:06:41 +0000 Received: from GV1P250MB0737.EURP250.PROD.OUTLOOK.COM ([fe80::4a3b:cf76:cddc:c68d]) by GV1P250MB0737.EURP250.PROD.OUTLOOK.COM ([fe80::4a3b:cf76:cddc:c68d%4]) with mapi id 15.20.7386.025; Sat, 23 Mar 2024 02:06:41 +0000 From: Andreas Rheinhardt To: ffmpeg-devel@ffmpeg.org Date: Sat, 23 Mar 2024 03:06:18 +0100 Message-ID: X-Mailer: git-send-email 2.40.1 In-Reply-To: References: X-TMN: [uMATfx6b04l8M1H6xaPt12eGZFMchSoY/2fVcVBVmTw=] X-ClientProxiedBy: ZR0P278CA0005.CHEP278.PROD.OUTLOOK.COM (2603:10a6:910:16::15) To GV1P250MB0737.EURP250.PROD.OUTLOOK.COM (2603:10a6:150:8e::17) X-Microsoft-Original-Message-ID: <20240323020623.1570961-9-andreas.rheinhardt@outlook.com> MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: GV1P250MB0737:EE_|AM8P250MB0137:EE_ X-MS-Office365-Filtering-Correlation-Id: 5c9de8d9-95ac-43d9-64e0-08dc4adde19d X-MS-Exchange-SLBlob-MailProps: Cq7lScuPrnqkjmXb1vlddM5aSa/Epk3A+VhfcnrVACgs6QaDndxlgh1BRc3vggd/MIyhUMcWaFeiOHg00laFygj8kUhut1JntFmOasOuT6+l0R4e6/2qdBgirlW/r4QYfe0EGBLMAhL4GYWabMhy9lzYMs6eBaYXxEgc/FMFmD0Jv8WqL1mN9f9YXrVnBTF1evglbDjqr/uII/bNM3homWhroPE3B6c44esYBVqGvxLIkFfxTLNJjh8ZTd6sJOAivtO1d7lrOy/6wc3Xp7YckRvD/hMdS2avyZOku6BmkkNfsfeDxJcDxKmXdn0N+m3K7yzUukF4MqKfxhCenzkEBvVetz32Ld3BRJ8RtDceWYXGSqTLNy0Tfakajy+lcji68imcB+a+EGS06Z0roGh6UOCQuMTTBjytxlifyPiCfoG4LxtzTBE5G4KRFz64wNM/u0s+U+OFicSZdGYnK1IdzbKLYJhGH/3yeM/+L0gIXbcPmLXePFEaa5HOdogBmgdy93WkYA5v5bPx4p6Ax//bJkcnbUboNyzY6DNw31F/GZjQamaQcDXAdPK5oYh9HhPRE34QcYh2UK7pqOrUZs1RW/+SRzJW05R0mRLdx0Rxiw+YIZ4VWLmgcQ+9z4Gdau7PMuZC3d3fFlRiNGWrjhLyToq8iT5mI9Z/LRmve4UswAehtsFbYksAx+PGrclA+IXN7spbWJMbI0YgbPlkU72KDoSzF5KSfxL00pWju+EH8p1OhJzGzuS3AdYrCJ3Jx3pyNGztnyVvHMQ= X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: Q3eMQh5nsoaK/dHl2fmB4s4628FK5nOgjmhEpefFQB5f+bVgrhjfEWndj6Kjkjbn7C0OSmNlR82+TO8BPj4+LtOt/buWCHSHHtRhcyIdkAh3cyFvw7Fc5FTr3AIZBBBNTNgiQQ5BSByFlw+caO3a+GY5htdRHPHDlsSSYe/2PGr9hwnbKMjRKAGjegzOL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TueZkjM2X0iJdwFjglUPs0e6mbJckSC0ZhBtBuLyISxbnM88yhOwl33U87EOzDGp3wkn4vg2wtoCIxuv+cDw2uqQImiMB7UbmUKkpzXcsxR6Vcl3/x6IpGMKq2jRCGOUr1i0K9be4s9IVRvY+OXST8c6SwejBFR3hTDT37IhoBfQJ1C/IoDcsBGSArTAG7i7kvDrTjX0wRxOJU+cIPxPz70HJJBLUeHamV9Cpkmdn19rE8WGgqFNHj5oHsZOyzO91Qhlx6jrW3ccQHAwtm1nFc0XFGm4RLgl68Ca/JBSJySwFgIWEh3+1i+7ZsOO2frTii3CFa1gA0QKWIAKF3RCGxTOSlkMnPNIU+i6zZ1ieUvNGnYEYL0X9kndMhAeJq87Cp9XRKPuLEe/uJlF8wtWXpKtA896vCUh1gA+YR7WPMGmb77ODboVgysH+UAlNMwX1X+h4Xltr8KpkM3+BykGYNHlufReMER5i5EM9u+akrCjPGME14Z7X13eYxDKuMusVXPXtfIET9PDmL6RzvocQ0ejLMSUMupC+iWQn+PLRIobzzt5QbI7Z9+VKuZnkeRwnuRTFQrAJ1bYix4Urn6v7fy2Q5yOzhayA0AbWSAfpxKtGiwfdGWNPnQHkVfiHP1qeDSVR+qKK3euSrYAsLEqsBTmyFvKcEweMqgehmvAF3wUhHKXQjvwCXyswKed3i7eyRyo8pxQXhp7Qd9xxXfwpyO5GoMrVJJ5K51A== X-OriginatorOrg: outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: 5c9de8d9-95ac-43d9-64e0-08dc4adde19d X-MS-Exchange-CrossTenant-AuthSource: GV1P250MB0737.EURP250.PROD.OUTLOOK.COM X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 23 Mar 2024 02:06:41.5715 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 84df9e7f-e9f6-40af-b435-aaaaaaaaaaaa X-MS-Exchange-CrossTenant-RMS-PersistedConsumerOrg: 00000000-0000-0000-0000-000000000000 X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM8P250MB0137 Subject: [FFmpeg-devel] [PATCH 10/15] avformat/lafdec: Fix shadowing 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 Cc: Andreas Rheinhardt Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" X-TUID: 4wmiI0MQuHIM Signed-off-by: Andreas Rheinhardt --- libavformat/lafdec.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/libavformat/lafdec.c b/libavformat/lafdec.c index 05f30691ba..77eab2ea6b 100644 --- a/libavformat/lafdec.c +++ b/libavformat/lafdec.c @@ -148,8 +148,8 @@ static int laf_read_header(AVFormatContext *ctx) if (!s->data) return AVERROR(ENOMEM); - for (int st = 0; st < st_count; st++) { - StreamParams *stp = &s->p[st]; + for (unsigned i = 0; i < st_count; i++) { + StreamParams *stp = &s->p[i]; AVCodecParameters *par; AVStream *st = avformat_new_stream(ctx, NULL); if (!st) From patchwork Sat Mar 23 02:06:19 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andreas Rheinhardt X-Patchwork-Id: 47357 Delivered-To: ffmpegpatchwork2@gmail.com Received: by 2002:a05:6a21:1014:b0:1a3:ac71:9534 with SMTP id nk20csp286078pzb; Fri, 22 Mar 2024 19:07:53 -0700 (PDT) X-Forwarded-Encrypted: i=2; AJvYcCXemmUSk/Qc61ZbE45E3J+P65rg535CREH4dItYoFCRaWU5m0G5EYiWpLMusDAA+JsMp3bPphIfIpKLvKUXpJ4s63JdKKpz9JrqMg== X-Google-Smtp-Source: AGHT+IFpdQXXE9UKttqK+QJ7iKHj4J/3A4/m9MPGo4HnUEOBtbhAdfCXyfewcuDSFwFxBruTxf2y X-Received: by 2002:a05:6000:146:b0:33d:9231:d1c2 with SMTP id r6-20020a056000014600b0033d9231d1c2mr692491wrx.25.1711159673058; Fri, 22 Mar 2024 19:07:53 -0700 (PDT) Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org. [79.124.17.100]) by mx.google.com with ESMTP id k17-20020a170906055100b00a47226db77asi340157eja.484.2024.03.22.19.07.52; Fri, 22 Mar 2024 19:07:53 -0700 (PDT) Received-SPF: pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) client-ip=79.124.17.100; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@outlook.com header.s=selector1 header.b=ZYeDzV7o; arc=fail (body hash mismatch); spf=pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) smtp.mailfrom=ffmpeg-devel-bounces@ffmpeg.org; dmarc=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=outlook.com Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id D5B9368D5FA; Sat, 23 Mar 2024 04:06:57 +0200 (EET) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from EUR04-DB3-obe.outbound.protection.outlook.com (mail-db3eur04olkn2050.outbound.protection.outlook.com [40.92.74.50]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id 3852768D5D9 for ; Sat, 23 Mar 2024 04:06:54 +0200 (EET) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=Xkwm+HjQE42e6fwIcIBFbVqCYLDLZh/kwv/chKm0YyIUv/knhyTmXABZdNkmdxUFCJKDcvR+IMnrQ044jniMa3NAroPdSvjCsolhGRpugerEOGb+ZQWy65U7Zra1F6Zix7//giv6AG98mBH/d/FL6nZaqVScdQlE1tJupZGgfPx27f/wMkJc3U+nhDBAI6UYrqGWmTJNY7gqEP3qCQ6g5qI4zFe0jCRvktTE//4yzrcEwBiDdZaGKLa7KymuDOhPZ17kBC9F7El1J4JHIw6PX+4pgEWkOfqgwPRerTMqY9vauOfdxyBIBj9YhfZnFSBcT/7kEmnc9sYJoLKlwGz7FQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=1C1YZgd1b/+5WvCGQSWq4vJUSUGNVDN3dzEpTHLCr08=; b=A97gHyIxJPtnk5kcEyNvxg2uk0lg895MuIpkFPOLHpcgq6bLLfB7om1UbqlKytulUso7a7sXwQuF93Ci/cd+4XbJD3O0npnoGbHwJKqXBFyV2ZIySush7Aefd0jtleEhG15in1HryINsGgJn2DZhjlNgUe+FoNvSOSjRG2kTsb2UbRCA6YpWCtVHmaJoHYonP1U4BYfkf2ntssjwdH6bfi/8wqJL26G6CYKfZWMDUGh8WEG1YsvUypdRV7ArH6VXENkAOqlif/ZZbtQCDxovyWRMkUl+druMkkpGiwy0Xv4loS8crbJlC79w5yy3izO3obI+9/WSOJANRs/LK94mdA== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=none; dmarc=none; dkim=none; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=outlook.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=1C1YZgd1b/+5WvCGQSWq4vJUSUGNVDN3dzEpTHLCr08=; b=ZYeDzV7ozNGuiXi7kf/L2rp7v+tGXZ9pBcgCyKiFZ80+yRgEenJ595Rxu86TQy4SKR4TXTOIjZo3lLkaj748IsKpJQjAHsyvGgSOTL5mCdjtzWDc0PAuIn/56Dk16Pf1SV8iSWEiXwX0BmCfd7/SL5IfFPZJhk4kEyk8RGD7/0N8mUM1dcPTFfpg3vJVYxXx9mpccZON503pamyJ0SziTdTRVl7czKCLEBENw7nBZDicWh2FrNbmg2FhEXj1Misw2pgakWKnH5eEdNpw4s7HWy+mtrATwGMUzQe2unapUaVuw95dLgRnfaG6Uxt8G58YX+OvA/jhylCgJY4iksuKXg== Received: from GV1P250MB0737.EURP250.PROD.OUTLOOK.COM (2603:10a6:150:8e::17) by AM8P250MB0137.EURP250.PROD.OUTLOOK.COM (2603:10a6:20b:320::11) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7409.24; Sat, 23 Mar 2024 02:06:42 +0000 Received: from GV1P250MB0737.EURP250.PROD.OUTLOOK.COM ([fe80::4a3b:cf76:cddc:c68d]) by GV1P250MB0737.EURP250.PROD.OUTLOOK.COM ([fe80::4a3b:cf76:cddc:c68d%4]) with mapi id 15.20.7386.025; Sat, 23 Mar 2024 02:06:42 +0000 From: Andreas Rheinhardt To: ffmpeg-devel@ffmpeg.org Date: Sat, 23 Mar 2024 03:06:19 +0100 Message-ID: X-Mailer: git-send-email 2.40.1 In-Reply-To: References: X-TMN: [idoTmcqutK+xnL6a+KErubdHVyba8NSJVgH/ivPjL/A=] X-ClientProxiedBy: ZR0P278CA0005.CHEP278.PROD.OUTLOOK.COM (2603:10a6:910:16::15) To GV1P250MB0737.EURP250.PROD.OUTLOOK.COM (2603:10a6:150:8e::17) X-Microsoft-Original-Message-ID: <20240323020623.1570961-10-andreas.rheinhardt@outlook.com> MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: GV1P250MB0737:EE_|AM8P250MB0137:EE_ X-MS-Office365-Filtering-Correlation-Id: b64a53db-9299-407b-293f-08dc4adde25e X-MS-Exchange-SLBlob-MailProps: Cq7lScuPrnqkjmXb1vlddM5aSa/Epk3Ac2AKWyGUUPZx+CHMBId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F8ASwKDa/oHTVR2Cf8XKehL8Sxr1HjX8N25O6a/dNXUzGnf570EjhEwFgXjytxXqocSpEWqMfgChdtbvVYvL3RWRSyuu4mt9OVQ/oXA2+qFMrjTiP9ooX3nnYAd3x6JdvcBJ0E7MinCfsbDWZ5wEx1kOtSFVQXNLQMdOZsOrnTcjhng2AvwdGaItxHmHxs/gE9Z6f0ebERtr2CtYtnLz0tHcqxJzT8OSoXApZpynbAuRZrDdAhO8LXahrBmOJHVfUIXhf8w4q4rvwP8TfgbJD+pk7ARR7xk/8mU8d7iar6/ekeKdYMFCvg7p5B20gn9LUQWROHA8voVU2gDtxlokIGdbDk4iWym94O/ReJPwhFfCdGLPO3iaBSRpUl6HbmtCyOcgLpTUXeokPj6JUIAcvrqpX4TJZHlMTWF2NU890e8pYi/+C4bxYRlh3FM/zYcYzEmim7/NuoL8bCwLVtNjuLhrPAII0GsWh2DQL+A/RFfP0j/oMhsdLTjfa5FTkWLWmtncRRKEmtZu/8RMr3QG8WipgMBPPfbtyDmP2JLgnSZ05PcZVF5zsSYcE6hFnr+NchDVgNyMLcnGQkNiEQOs5506vLGw== X-OriginatorOrg: outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: b64a53db-9299-407b-293f-08dc4adde25e X-MS-Exchange-CrossTenant-AuthSource: GV1P250MB0737.EURP250.PROD.OUTLOOK.COM X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 23 Mar 2024 02:06:42.8263 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 84df9e7f-e9f6-40af-b435-aaaaaaaaaaaa X-MS-Exchange-CrossTenant-RMS-PersistedConsumerOrg: 00000000-0000-0000-0000-000000000000 X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM8P250MB0137 Subject: [FFmpeg-devel] [PATCH 11/15] avformat/cdg: Don't store avio_size() return value in int 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 Cc: Andreas Rheinhardt Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" X-TUID: ZgH458BozwyO Signed-off-by: Andreas Rheinhardt --- libavformat/cdg.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libavformat/cdg.c b/libavformat/cdg.c index 2030cdff89..43d919e302 100644 --- a/libavformat/cdg.c +++ b/libavformat/cdg.c @@ -46,7 +46,7 @@ static int read_probe(const AVProbeData *p) static int read_header(AVFormatContext *s) { AVStream *vst; - int ret; + int64_t ret; vst = avformat_new_stream(s, NULL); if (!vst) From patchwork Sat Mar 23 02:06:20 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andreas Rheinhardt X-Patchwork-Id: 47358 Delivered-To: ffmpegpatchwork2@gmail.com Received: by 2002:a05:6a21:1014:b0:1a3:ac71:9534 with SMTP id nk20csp286127pzb; Fri, 22 Mar 2024 19:08:01 -0700 (PDT) X-Forwarded-Encrypted: i=2; AJvYcCXMsWYEUcTIyFEqzBqkZ7ttVuW2MvTsElDqpm/UjhXiwRG5GU1RdNiLoHzvLHB/fZk3ovIJ3qY1E21fSJqIm60a8ixjj36fjudUHQ== X-Google-Smtp-Source: AGHT+IHTiB0DbBBcZA1dgoRDLVpH39mmzBwy0MINALlmmJUMw4KBZAF6um1mEh12aN3uQtLsvozB X-Received: by 2002:a17:906:ae9a:b0:a44:7209:4c93 with SMTP id md26-20020a170906ae9a00b00a4472094c93mr811686ejb.32.1711159681364; Fri, 22 Mar 2024 19:08:01 -0700 (PDT) Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org. [79.124.17.100]) by mx.google.com with ESMTP id i13-20020a17090671cd00b00a462fa16055si366952ejk.313.2024.03.22.19.08.01; Fri, 22 Mar 2024 19:08:01 -0700 (PDT) Received-SPF: pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) client-ip=79.124.17.100; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@outlook.com header.s=selector1 header.b=WA1TdGPv; arc=fail (body hash mismatch); spf=pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) smtp.mailfrom=ffmpeg-devel-bounces@ffmpeg.org; dmarc=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=outlook.com Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id CB31468D601; Sat, 23 Mar 2024 04:06:58 +0200 (EET) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from EUR04-DB3-obe.outbound.protection.outlook.com (mail-db3eur04olkn2050.outbound.protection.outlook.com [40.92.74.50]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id 5CEB968D5DE for ; Sat, 23 Mar 2024 04:06:54 +0200 (EET) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=W9uTja9TGPO32sTeM5iJ5q5v1ZfRLbHv+KgXYlDTS5l/UkOI4LNLyG2w48ad3XWGG4LiTnruftHgxQGL5QlLY4n71wxEFjHeV50BMe7Vqz81EtF2T5mIWvsjYaMtupNN0LvG6Z4BCu/vlPugsF4IrXdzBTpH1sn8m9F6OQ3RfuLegAAfo8IK4UkUYgl/V4MFH5rcOPrvFT2tBlOjQfvIJ+TnfbCSLlTJHOhuBm8o6/u/pr1x4erF9j/nvzTyLJCHNOqTaU67vyWZRg/DpBX+48dgAkq3k2lSCwSAOMRP0Dsktb4GDAWQtLM/avK6LHcUQojLDVKaOqrD4R2r7dtG7A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=b/8Ii/gQD+aeWLHfL9etqXGayqiWX9TB7kLRyOzzsT8=; b=XjKKoStuzjPzGAxiMCY+KjCBU0bWD4EPIsF7vnbUAQJ17P8AcefzQjDI3jLDJBdIOwpeIjEyYpEWkOvHv7A4OK7Mg6D8aA9WCYKaeeGLx+DbXNp0zvCZw3WCnmxGEQCgVCKGWs1GE2p190YQ9N3F48eNe4PmGhm26bGYApeWTz5LKxhI3Ukh1Xn2HBbt6jVO6rzK6wk10KgzhO547NtM37LS1NmqWxyLgtbUQK9+iUyvpfLSxQ5YSNxw5Ht5nE2eiLN9RrznH8vgN/8AoSDinIDLAiYw+HFczUdoKP+xGxVX2nkQI4eQwig23dSnvaP38jlSeq/ZXhBu1/6kcCkcFg== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=none; dmarc=none; dkim=none; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=outlook.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=b/8Ii/gQD+aeWLHfL9etqXGayqiWX9TB7kLRyOzzsT8=; b=WA1TdGPvv5LBX6R4EpLHhd8DvVWM2Yn16SQmsS3iQrnn/ys/Jm2J/G527ZlxBYWmYFc32Gor8F4fjEDWgj0kq8TXqE3cRMIxLrq2jlAEc4ulIsALgIInkrkJCZQf0oSeaQrnFkEEZjyVz0jWlNjQZXaQq+7WOglM+ENYtn5vzWQnvinxdF8cxSh97H1aQ5lPsEdd3jgHl/0OSzQEvz4+D3kYGFyjX7+jPo48FKP+RLam5yKWqjklPdyl4OQsDuQxG6fUW1RyyQ8uOgoFcHzLqPZdYomIAVBlLZcCjYbowTMfwm97WBdIJca5liXT8jLj2yXQVaSCaPHn8sLNLv4j7A== Received: from GV1P250MB0737.EURP250.PROD.OUTLOOK.COM (2603:10a6:150:8e::17) by AM8P250MB0137.EURP250.PROD.OUTLOOK.COM (2603:10a6:20b:320::11) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7409.24; Sat, 23 Mar 2024 02:06:44 +0000 Received: from GV1P250MB0737.EURP250.PROD.OUTLOOK.COM ([fe80::4a3b:cf76:cddc:c68d]) by GV1P250MB0737.EURP250.PROD.OUTLOOK.COM ([fe80::4a3b:cf76:cddc:c68d%4]) with mapi id 15.20.7386.025; Sat, 23 Mar 2024 02:06:44 +0000 From: Andreas Rheinhardt To: ffmpeg-devel@ffmpeg.org Date: Sat, 23 Mar 2024 03:06:20 +0100 Message-ID: X-Mailer: git-send-email 2.40.1 In-Reply-To: References: X-TMN: [Nd8TmA0lpK64o4aDKK9Y+aprL+phggt9FsjdvmQBj9Y=] X-ClientProxiedBy: ZR0P278CA0005.CHEP278.PROD.OUTLOOK.COM (2603:10a6:910:16::15) To GV1P250MB0737.EURP250.PROD.OUTLOOK.COM (2603:10a6:150:8e::17) X-Microsoft-Original-Message-ID: <20240323020623.1570961-11-andreas.rheinhardt@outlook.com> MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: GV1P250MB0737:EE_|AM8P250MB0137:EE_ X-MS-Office365-Filtering-Correlation-Id: 7a17df82-1664-408c-9b71-08dc4adde344 X-MS-Exchange-SLBlob-MailProps: Cq7lScuPrnqkjmXb1vlddM5aSa/Epk3AIxNrDDp5iEsJhW8fX9CWE+q2sQufBCH8WcvMSvWwArVxKBTG7OrTPbvsUoF8jpSkMWuT/6CFigKGj7ZbCKkD7l04x/iHKcNmY7Y27dsA5Dj9JBNqVktyUK8hqcvcn5kkuQEbPZB1M8Rszo7CBmrGGrbKhaK5lR/fB9epq+aTEjyVn4iOaxKf/H9X4G44MLhP8OJESfMCxm4f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EGin4/cAH4fWf5WHL6PiFG7mzvM6OGT94G1/fZiYAQavJVFojCMdr0dhYsGa6E28zQrFeUpuv+lzgNUfNW9W3uW8HegaeFwX+zAFMhRbAcYe9MipE5FJfEgM+urF9fz3rTIzrJE4z/EeLwYw3Gxbl4YyGUt8ELh/G4aRGvk0yAFNmh9VXVKVyROuTjO1fVsPaU4DwhtWWIR212iL3eUp+lU3T9v4aZn0MH0+3Mr/MQepD/tr1H3BJa3+bZmmkFzToUuDqm0UdU53333ctSw1+fjVccoO+euvSUtz6XTBTNAfTZhMXT0GUTohSkSDgWSle2Afg92SA8uFJQupaHRvbkBRiKnz57APZCjCS6M7+YJZ8c2WYsvdi6VMgc5hXJ8/64mdIoz996RMGfoh86E/hRYsatTWDSKFwMrzgFKWEviw== X-OriginatorOrg: outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: 7a17df82-1664-408c-9b71-08dc4adde344 X-MS-Exchange-CrossTenant-AuthSource: GV1P250MB0737.EURP250.PROD.OUTLOOK.COM X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 23 Mar 2024 02:06:44.2790 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 84df9e7f-e9f6-40af-b435-aaaaaaaaaaaa X-MS-Exchange-CrossTenant-RMS-PersistedConsumerOrg: 00000000-0000-0000-0000-000000000000 X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM8P250MB0137 Subject: [FFmpeg-devel] [PATCH 12/15] avformat/pcmdec: Avoid av_freep(&(void*){NULL}) 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 Cc: Andreas Rheinhardt Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" X-TUID: xxPoOy6o5ln9 Signed-off-by: Andreas Rheinhardt --- libavformat/pcmdec.c | 61 ++++++++++++++++++++++++++++---------------- 1 file changed, 39 insertions(+), 22 deletions(-) diff --git a/libavformat/pcmdec.c b/libavformat/pcmdec.c index e9c97f7959..03feefb5bb 100644 --- a/libavformat/pcmdec.c +++ b/libavformat/pcmdec.c @@ -37,31 +37,20 @@ typedef struct PCMAudioDemuxerContext { AVChannelLayout ch_layout; } PCMAudioDemuxerContext; -static int pcm_read_header(AVFormatContext *s) +static int pcm_handle_mime_type(AVFormatContext *s, const char *prefix, + AVCodecParameters *par) { - PCMAudioDemuxerContext *s1 = s->priv_data; - AVCodecParameters *par; - AVStream *st; + int rate = 0, channels = 0, little_endian = 0; uint8_t *mime_type = NULL; - int ret; + const char *options; - st = avformat_new_stream(s, NULL); - if (!st) - return AVERROR(ENOMEM); - par = st->codecpar; + av_opt_get(s->pb, "mime_type", AV_OPT_SEARCH_CHILDREN, &mime_type); + if (!mime_type) + return 0; - par->codec_type = AVMEDIA_TYPE_AUDIO; - par->codec_id = ffifmt(s->iformat)->raw_codec_id; - par->sample_rate = s1->sample_rate; - ret = av_channel_layout_copy(&par->ch_layout, &s1->ch_layout); - if (ret < 0) - return ret; + if (!av_stristart(mime_type, prefix, &options)) /* audio/L16 */ + goto end; - av_opt_get(s->pb, "mime_type", AV_OPT_SEARCH_CHILDREN, &mime_type); - if (mime_type && s->iformat->mime_type) { - int rate = 0, channels = 0, little_endian = 0; - const char *options; - if (av_stristart(mime_type, s->iformat->mime_type, &options)) { /* audio/L16 */ while (options = strchr(options, ';')) { options++; if (!rate) @@ -89,10 +78,38 @@ static int pcm_read_header(AVFormatContext *s) } if (little_endian) par->codec_id = AV_CODEC_ID_PCM_S16LE; - } - } + +end: av_freep(&mime_type); + return 0; +} + +static int pcm_read_header(AVFormatContext *s) +{ + PCMAudioDemuxerContext *s1 = s->priv_data; + AVCodecParameters *par; + AVStream *st; + int ret; + + st = avformat_new_stream(s, NULL); + if (!st) + return AVERROR(ENOMEM); + par = st->codecpar; + + par->codec_type = AVMEDIA_TYPE_AUDIO; + par->codec_id = ffifmt(s->iformat)->raw_codec_id; + par->sample_rate = s1->sample_rate; + ret = av_channel_layout_copy(&par->ch_layout, &s1->ch_layout); + if (ret < 0) + return ret; + + if (s->iformat->mime_type) { + ret = pcm_handle_mime_type(s, s->iformat->mime_type, par); + if (ret < 0) + return ret; + } + par->bits_per_coded_sample = av_get_bits_per_sample(par->codec_id); av_assert0(par->bits_per_coded_sample > 0); From patchwork Sat Mar 23 02:06:21 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andreas Rheinhardt X-Patchwork-Id: 47359 Delivered-To: ffmpegpatchwork2@gmail.com Received: by 2002:a05:6a21:1014:b0:1a3:ac71:9534 with SMTP id nk20csp286156pzb; Fri, 22 Mar 2024 19:08:10 -0700 (PDT) X-Forwarded-Encrypted: i=2; AJvYcCW4TNTydq3ICPtRPGJf/29NZRgc3rY86xuTHQ2pOBxgaQ7G5+DKejvhqo3g5C/05gWN3ouEWfjO6IRd5rl3Kbf4w4kNl+v4JBfoXg== X-Google-Smtp-Source: AGHT+IHKHx3nc6qd2RTn6P9hkt5KFnrIW3KoHVHYpTm0wlgL1oQ/zmpvriOktbUZVXI6UOvu6BGP X-Received: by 2002:a50:a69e:0:b0:56b:c210:870c with SMTP id e30-20020a50a69e000000b0056bc210870cmr710298edc.15.1711159690350; Fri, 22 Mar 2024 19:08:10 -0700 (PDT) Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org. [79.124.17.100]) by mx.google.com with ESMTP id g20-20020a50ee14000000b00566e2d8715bsi356780eds.527.2024.03.22.19.08.09; Fri, 22 Mar 2024 19:08:10 -0700 (PDT) Received-SPF: pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) client-ip=79.124.17.100; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@outlook.com header.s=selector1 header.b="I7NtX5/1"; arc=fail (body hash mismatch); spf=pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) smtp.mailfrom=ffmpeg-devel-bounces@ffmpeg.org; dmarc=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=outlook.com Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id ADAD868D605; Sat, 23 Mar 2024 04:06:59 +0200 (EET) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from EUR04-DB3-obe.outbound.protection.outlook.com (mail-db3eur04olkn2050.outbound.protection.outlook.com [40.92.74.50]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id 8484468D5E1 for ; Sat, 23 Mar 2024 04:06:54 +0200 (EET) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=Ls/J4PBAKsQK8eL2CeexTF4vLctsJaFuu7zHy9DpnE2pAVpe7kWm3Q8rjtXW+SU470B3Dib0bPIXHLK+W/sx442WovtBmTrh/BYllS+RN1mzEZSTlyQQxNmWNYtS/msQvpJtqTS0uT9Mfv5ynJ50Y2PuUfODdwY50EyCkD7vZFQQj9KE3qaC3KRXCJx/IyZLkdK3UPKThAhhHF+y12ojVaCoIaGHcHyV1VUWqZ6fkXeU1EJ6yOZscaR6dqn2nam7J3rtZ9m6Kn1DfZbUvlEnEYHnXJlMNYWHCF7n5CSCVekL2PK0kfRhEvNyBUpkC5uR0IXJeRL+zRV5gz+YndtX/g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=0RtaIL1Ih+3ETSswCxym4UYMoTYPSh6cU4wGRGGyiPY=; b=kB+MDT+Re8d3P0MmG2mFDyS7PHlgclVeOa9sS9BMinMuOPJZXyQ05NEYep+d+yxitDSXVe2HOkrkgCxbdlAboxY2wpXCLmOFDa9a/Ann1TDikeinq+Zd5NtbZsOpwbdN/oLr7/IUcSAcghJs6uFn9MQV5YhoaSakiNs5/KlSn+oUhte0n8tPa0nmVVdswFasPcX6R+ruXDh8vcKvs5ATQueTya8ZDvgRaLAmGUn4ASx0m8wENJbf91cNEj5akW943ufgZZ0A/nCTD1VHVt4pgzBXM36AwfWzH//Y38qyG7wHjQLf9L9BhpGwbiT2H095XfVLZySssWJQRtZKQv7JaQ== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=none; dmarc=none; dkim=none; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=outlook.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=0RtaIL1Ih+3ETSswCxym4UYMoTYPSh6cU4wGRGGyiPY=; b=I7NtX5/129xVEwgKaiFBdmqxLoE+vFyU9fnlkYoBIkIMr+W1iscUrKanB1zbkODoJkY6unQjuaI/kzc9Al064psZyYBoHRjXKm7gbUFQ7dMBIPDmhGm3d6WsJM7QephIjPlI2fOv+s5fH8yhSQUjDC0awp+lDMuBJWwzazL94trBzBpOCC7VVjqp9hGljnBB5C8PmJzYSBkdPWct/EvgT9hm2y0kaRjMg/By0sNGYjzBjrUMCwmr4yas+Lr2yI/9ESKrRRJD4r0VP3NHmITeest5t/1sAf5HHqGAiZDIjdpg1DVZKw559p+kXfLv8lsQOeT/j6uI/lQt0tOwFlu6aw== Received: from GV1P250MB0737.EURP250.PROD.OUTLOOK.COM (2603:10a6:150:8e::17) by AM8P250MB0137.EURP250.PROD.OUTLOOK.COM (2603:10a6:20b:320::11) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7409.24; Sat, 23 Mar 2024 02:06:45 +0000 Received: from GV1P250MB0737.EURP250.PROD.OUTLOOK.COM ([fe80::4a3b:cf76:cddc:c68d]) by GV1P250MB0737.EURP250.PROD.OUTLOOK.COM ([fe80::4a3b:cf76:cddc:c68d%4]) with mapi id 15.20.7386.025; Sat, 23 Mar 2024 02:06:45 +0000 From: Andreas Rheinhardt To: ffmpeg-devel@ffmpeg.org Date: Sat, 23 Mar 2024 03:06:21 +0100 Message-ID: X-Mailer: git-send-email 2.40.1 In-Reply-To: References: X-TMN: [eUkDWij/v9pNCLIEh3bC9RfkHM3A/vFQi99PJyQDh1I=] X-ClientProxiedBy: ZR0P278CA0005.CHEP278.PROD.OUTLOOK.COM (2603:10a6:910:16::15) To GV1P250MB0737.EURP250.PROD.OUTLOOK.COM (2603:10a6:150:8e::17) X-Microsoft-Original-Message-ID: <20240323020623.1570961-12-andreas.rheinhardt@outlook.com> MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: GV1P250MB0737:EE_|AM8P250MB0137:EE_ X-MS-Office365-Filtering-Correlation-Id: 3082a93c-a8da-4ca1-7e21-08dc4adde3f7 X-MS-Exchange-SLBlob-MailProps: Cq7lScuPrnqkjmXb1vlddM5aSa/Epk3Azfj4ZJduqG8fnG35xIgtIthaNc9rcN8CWtqhvlOnEfEzOy0iFBvDFwkJFO4uYkRTc+IKCddiHkLmr2saeAmkpdDsEclZ1sGGws0HkT1xXF66UjB6bm/fLul6x9EVu43vmvKWZbELS7GULpCsFOJHRmsDYkrbVzPnmOFsGgDvyKFaQVYlXUNvfVx+QPwrhjEEyjH/AJ8C9wdekiZmIfgEXwJDI7VWANkTIKkbuc0g0eZOqjwr1qURmsrJNf5DEdSNjmvptms1+Q2BS8hGWQ7K3gFjHVml23w2+17fyUzIS6Pw4PYaoOiyXJoN3T3xEEq8ct2pJl1x/7V5JxABJlnpAv9wz1CbDICQWpD9Oep4Y2idQxVMk63HbMHWTmEKhYYNJp+BMMi+mkXLybuNoXKwxfh8uvZNLPYDWv1CFwMiPNJDtMzDyvrhdXZveMab3FCa2VoOBchG9hDb29EN5lBQx0OAIuFjZTmQHGkfzBf38Xh7w66CX73Yi084Z2sdGqfQ02xjViUULxbrkbK+2gkZve17KPeoTqvV0dLFLw4fv8eJkzjq0AfWHhY1Ia28ezHL7RTq1UYPzapIVT6JrcT03lq55SeRccOn360uYAlIf3IUuo5OREdrWdFjACFf1Bd39ap2SZEumCqULLGUG6YCvnOSoFclWd7aUBiAEZ8b2chs3oZP0IsGgzRfOZPI6SyoVDdgVR4mBtRsPoRdbsmooYvY3+cleaOwv3QqGvSSHlU= X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: YMTjWXRszIKmRKlpZB9FGC8gK+siWGFCr2DunWSm6e93SYqy3WhYym2GUMjKMoGyZQHRCExz4pHnK0pxGeVmUaUgV75ePxvHRNBKUgVBRnh9olLFelVHVZZTVmRb9FPHoLZ6qsbtzH8NuhyR77vGC8hLcgin53P2hYE9KiahmWEcPVp7AQTpZYvV13wndrrPiRfQW0CsPp/UnO2YgZfiYBTGAaJ85lnKbBDaSjJdM99GjEsgimfISBe7P6uHzIOVpMxcQ9sY6XONXS9WW1a9zXNcYiOtkrIoqV+dX5Td4cXrCG+GfjJqVhlYsfPt5igMjMW58Yxu8r3000wZPSGxwShR86OI2mI4j258VKt6ZC8xRv+TWCrml8d/beoshrpOnwA7MohVBDjrua3N28aD2AvyMvnalnU6v7q0wQ3Od1VMHQY9bZXyaFlkEeBVPmM2m80iWkCC+1vm6R1w8QaDE2WC3y4O5rjK8ee7J1gw6Kt+zz1aNRrFhZj2R3nU5sFtUjAx3khaAcCapOpKuYi6+2VcpxEiWsjCAh0WsjpRo0grikPU7FZWT5mskmfyYe+Lzk23N5nj/yeeXKqQrnWkaaDhDKBBuW+B5L3euSi/XRY5JwD9jE0jndCX8pWXbGMD X-MS-Exchange-AntiSpam-MessageData-ChunkCount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n21PggUonsXCXL7UABGSXGPaCTzUhjS9NB242t+wEFnTT5PDQH8p2jqXsmVTK5hdnqBKE7BiS4wk7DWjSXsmCgjAjUalsqeqrKe/OH7DzgLBnUUNDUOY7jrn8+YHgqBLk+vKa3KFPw/I9528LWckhTkjoXqCGLye6EIMoxowuC8GEw8xKBBCd6O425RP+DYKdJ7iF0+MkgAfhseCTCa/TriAjisL/GJ+BSvtj4B042HPf7kIeg== X-OriginatorOrg: outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: 3082a93c-a8da-4ca1-7e21-08dc4adde3f7 X-MS-Exchange-CrossTenant-AuthSource: GV1P250MB0737.EURP250.PROD.OUTLOOK.COM X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 23 Mar 2024 02:06:45.4612 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 84df9e7f-e9f6-40af-b435-aaaaaaaaaaaa X-MS-Exchange-CrossTenant-RMS-PersistedConsumerOrg: 00000000-0000-0000-0000-000000000000 X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM8P250MB0137 Subject: [FFmpeg-devel] [PATCH 13/15] avformat/pcmdec: Reindent after the previous commit 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 Cc: Andreas Rheinhardt Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" X-TUID: /vWccHsJyWvY Signed-off-by: Andreas Rheinhardt --- libavformat/pcmdec.c | 52 ++++++++++++++++++++++---------------------- 1 file changed, 26 insertions(+), 26 deletions(-) diff --git a/libavformat/pcmdec.c b/libavformat/pcmdec.c index 03feefb5bb..e95a08df4b 100644 --- a/libavformat/pcmdec.c +++ b/libavformat/pcmdec.c @@ -51,33 +51,33 @@ static int pcm_handle_mime_type(AVFormatContext *s, const char *prefix, if (!av_stristart(mime_type, prefix, &options)) /* audio/L16 */ goto end; - while (options = strchr(options, ';')) { - options++; - if (!rate) - sscanf(options, " rate=%d", &rate); - if (!channels) - sscanf(options, " channels=%d", &channels); - if (!little_endian) { - char val[sizeof("little-endian")]; - if (sscanf(options, " endianness=%13s", val) == 1) { - little_endian = strcmp(val, "little-endian") == 0; - } - } + while (options = strchr(options, ';')) { + options++; + if (!rate) + sscanf(options, " rate=%d", &rate); + if (!channels) + sscanf(options, " channels=%d", &channels); + if (!little_endian) { + char val[sizeof("little-endian")]; + if (sscanf(options, " endianness=%13s", val) == 1) { + little_endian = strcmp(val, "little-endian") == 0; } - if (rate <= 0) { - av_log(s, AV_LOG_ERROR, - "Invalid sample_rate found in mime_type \"%s\"\n", - mime_type); - av_freep(&mime_type); - return AVERROR_INVALIDDATA; - } - par->sample_rate = rate; - if (channels > 0) { - av_channel_layout_uninit(&par->ch_layout); - par->ch_layout.nb_channels = channels; - } - if (little_endian) - par->codec_id = AV_CODEC_ID_PCM_S16LE; + } + } + if (rate <= 0) { + av_log(s, AV_LOG_ERROR, + "Invalid sample_rate found in mime_type \"%s\"\n", + mime_type); + av_freep(&mime_type); + return AVERROR_INVALIDDATA; + } + par->sample_rate = rate; + if (channels > 0) { + av_channel_layout_uninit(&par->ch_layout); + par->ch_layout.nb_channels = channels; + } + if (little_endian) + par->codec_id = AV_CODEC_ID_PCM_S16LE; end: av_freep(&mime_type); From patchwork Sat Mar 23 02:06:22 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andreas Rheinhardt X-Patchwork-Id: 47361 Delivered-To: ffmpegpatchwork2@gmail.com Received: by 2002:a05:6a21:1014:b0:1a3:ac71:9534 with SMTP id nk20csp286230pzb; Fri, 22 Mar 2024 19:08:27 -0700 (PDT) X-Forwarded-Encrypted: i=2; AJvYcCX6WRxZSevKwze/275I77d1aWrPMHHd7xEY2hRiWT/YIeYgoJj/hmS/0VuZgTy0fddhoyvS2d72hTXxlYdLwUYWSz6LBIev2+X03g== X-Google-Smtp-Source: AGHT+IHxrDQf/HOHAFOTK0CijUEXoLIDTcWKdKdPTxTLV6AoEF7qA1+Nm6NNr3QDFu0SeLs+Ogdw X-Received: by 2002:a17:906:32ce:b0:a47:11c1:92d7 with SMTP id k14-20020a17090632ce00b00a4711c192d7mr904758ejk.69.1711159707128; Fri, 22 Mar 2024 19:08:27 -0700 (PDT) Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org. [79.124.17.100]) by mx.google.com with ESMTP id kq26-20020a170906abda00b00a46004324efsi383386ejb.521.2024.03.22.19.08.26; Fri, 22 Mar 2024 19:08:27 -0700 (PDT) Received-SPF: pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) client-ip=79.124.17.100; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@outlook.com header.s=selector1 header.b=BwDiKUFj; arc=fail (body hash mismatch); spf=pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) smtp.mailfrom=ffmpeg-devel-bounces@ffmpeg.org; dmarc=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=outlook.com Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id 8C93068D5DA; Sat, 23 Mar 2024 04:07:01 +0200 (EET) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from EUR04-DB3-obe.outbound.protection.outlook.com (mail-db3eur04olkn2050.outbound.protection.outlook.com [40.92.74.50]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id A967D68D5E3 for ; Sat, 23 Mar 2024 04:06:54 +0200 (EET) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=jIrRiAC8RYFK/VAU/ZfNVJVzNnAuJO7uWPfsCIz3BE31Z7dszpbSqoOrXIReAukokfPdganjTg2LlQTdBS2ACrWlwxexJBCCFJ3psTD66+ycyOBj8nOM8/g3fIOV/ro7IdnLiORIq4Ry7jvw9k9gd9TGpLHkkTve2LcWlmKrcHK7doyZR4AEvzMl7eJz6ZyOQnKNbxl6RyVJ5DpedLMlsll8OhFxa+ycAdQOjxsoS2F+k3r4hEe9gMGx7L9RqYjzhMpAX/7zaDkqM6Leipu3z/9ZzExszmd4OmtSTrrnmbyL0qT8T7ob5sNYiwx1RYyiTY/TBDzeIXFMA8AuNRXNhA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=zNOaGOZZZe5TeiOd8b7NpkmCKvgs2Fxz9Xs0kjRtL5U=; b=iWxnrz1pRCs/N6qK+FvO2kJsx5af11tVrRZioBdCvwFlIoL3PEf06Bp6lo93OsZ1itQJyxQCWN/aJZqgZaUw3u/CeuyhiXXcMaGiESI70YnhIoV6il+nA9tIqz02VmyibGSGsSXnxazulJeex7j75YVkEUFKnO+YQBD2MiiENQ9q6YHMtTaeW8mpHmkZQdFmOSBhFef+7KjfMx+QkZbIYTbM5pL9biCveH+zxAHLGT0f+lOMJq6BwjxTbfrRV5uT/tY4w2I80xxgUU8VLiNEG1dUwD01P8SQF0SqotN0iNFSe+H3j0rlm3MeEMUdzfCwMGRWlKifEg619aYQHmBn2w== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=none; dmarc=none; dkim=none; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=outlook.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=zNOaGOZZZe5TeiOd8b7NpkmCKvgs2Fxz9Xs0kjRtL5U=; b=BwDiKUFjOA8U4bfVkVa5jJpCVGZLNVjFkFATZxGksCJbGoWvUS6rtd3aqkyXeMvIUY+X0R7pvuw6lakIj7IrQw1+DfYvOLaXppM54npNXcQU91o94qRCn9wUS1mgIx4eSypLCpA7S30lAPoH7dYFmYCLg+nhmH8G+NK7QieuxIZCkwbhyiLRNpqQm8B3tQWYkCBQWUEnsmSevA8ZoPGmu1f+KnLvxlTUZM5olYPThX/IbU1DzsJuPD6FV0aHVRp/ZoTLnuyOGNNjdXvPOTK7r7vHj3QexUHK5t2FB43FA+xwQAWuGHXiEVxe+6Aj5VI7rrvaI4IKgfnrcJSiV0mhbA== Received: from GV1P250MB0737.EURP250.PROD.OUTLOOK.COM (2603:10a6:150:8e::17) by AM8P250MB0137.EURP250.PROD.OUTLOOK.COM (2603:10a6:20b:320::11) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7409.24; Sat, 23 Mar 2024 02:06:46 +0000 Received: from GV1P250MB0737.EURP250.PROD.OUTLOOK.COM ([fe80::4a3b:cf76:cddc:c68d]) by GV1P250MB0737.EURP250.PROD.OUTLOOK.COM ([fe80::4a3b:cf76:cddc:c68d%4]) with mapi id 15.20.7386.025; Sat, 23 Mar 2024 02:06:46 +0000 From: Andreas Rheinhardt To: ffmpeg-devel@ffmpeg.org Date: Sat, 23 Mar 2024 03:06:22 +0100 Message-ID: X-Mailer: git-send-email 2.40.1 In-Reply-To: References: X-TMN: [9gd/mTvCtkAV2IAaCzusALy5ir6TwN1nQOicvCVcZf8=] X-ClientProxiedBy: ZR0P278CA0005.CHEP278.PROD.OUTLOOK.COM (2603:10a6:910:16::15) To GV1P250MB0737.EURP250.PROD.OUTLOOK.COM (2603:10a6:150:8e::17) X-Microsoft-Original-Message-ID: <20240323020623.1570961-13-andreas.rheinhardt@outlook.com> MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: GV1P250MB0737:EE_|AM8P250MB0137:EE_ X-MS-Office365-Filtering-Correlation-Id: 2c1a0e8e-f3e3-4813-e5b8-08dc4adde4b9 X-MS-Exchange-SLBlob-MailProps: Cq7lScuPrnqkjmXb1vlddM5aSa/Epk3ABwzG02UKcyJJtpv0LhnBWlHAXPeG3GyWV60d16Ztxsyz7gTCaGIpN+71/TQJTwjBY8ZmDtICx0x5pKDdXnikN+uixZUr7G+dsoQ/DesRSCHQSUGqy4Gph3AMA8G3nfvRx5M43uchYKeMqBWxf7uDR4WrEh8+JpvmEAj0HuN+krlxlTjrRmXCjS4+ztEX3G0RK9A5Za3pCsqVb5eVBVCU3GUs7WLaw4UemLHZ9KD6/Oo7fgUPGpRiwzHpLnEjZo0V9mwJgn4r1ZbF6mrpg3BvCF6ePIPBhpR5nHSFAqmX3rMEtr0DNO4NeMF4ojzuqcgxXAivVbW+6uZB+p9ZFsZ8cUWnqj6zNuHlHBui/gFgpCFC3da0iYEUrwvBeRN483PLiYAZOVR93kBxCHNjinmGMBBNvpdk7VCXjehfjSnpcIxQdUX2JBBKxSQYt7bRZJEnup5d/cj7OJhcnR9avXPTHTorXW9dIy7a/TDO+AFMBoK2jsdS5LyiV+a7LEl5p4Ig8sgVimonAiUkg9o6Jbdg4Q2L325vXaRMV7EOJ0G4FIEn2V3AriuRHvwhCPI9N8WSfxMAzCV1HJ2wQXN0pnLZLetwR35BN0DA2DmQupMW0iYclTu1wjmwhUcS0aqqlyirJ/GJZEFWOTUBin+eW0slexVYNDXPqWAQFrvtdWaLoKuDKLl2BNjxjY8p427SRcWVAk4fsKaAAz0h7wvTBRl64iDxFNq9qJ0rmYdMd7CGuWM= X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: M61Zo8fBJN8hDxP1oRcLJHhYNTPLbOLSC6bv4o7wtZWoto7wvdfzb7WmRrgTdSBCimyetfsTGAMh1b6QFLVKg/7esZrBn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RED/S0Sxt5hL9RlFTXcKC6A/b5JAJPaFLpx7UZCjBVOefWYrPLtsuhMQjmJBY8VMOd+Y1gZJBNyYOPTwDTuC9cBGY2ZV7QnsRbeyEfwZeUOF0uUOV83Kh7cPS6IFae4cuJeMoDLoMeJQGp/3+sqOm4QkcCjcGfmQben6ZQPGzT1wJ1/KVd6gqTnDK1YbP9e7wsHyhDkQyDKNrt+e1izQRfxFI0wNdZyvbElkPCkYf0qFNbWv097GkcQxCp6OGu3v/3YGpg9bfGDlyQ99ebRpLG6ukV6066GPjn7xwSDH8VqQjF44hedmKQXxXaFO1prAxz6oIxC2q5x+A5Ml4ouGHbCeGcl4lAEpPOiD9/HYoavAb2bwes2zpZtmzsIHGfViwaeOMfdYcfIZa0piEgbcA0VtJmbq/5XtT0xyh2QIE683CQGJNThOuhA1eYWaZiRU3I8xvMBD3rLtp1BxB0Qeh0iaIGzqBxWZtQ4ZrcU8jztk3fKHIT9WzJKt1SVUytH+nxbh9rr/gbjWPNHUlH8cjydtcp697cBmoYjQSMYcUOSB2eG3Bk/+EhEozykiNjs+w5V0dsfutcK5PHEmURoBZeue5BmNjrXMVAYN816YAs20bD99PeT1tLnCqVsX1AiqNK8JS4w8Ocwq5KZhAlFgiEb1RcbiJFw6lLT2mGUMNU3vrpM9o2AaK4EtyKxX7kvgYrO3zrH0l2ixPhcnd53ZevH9k4UDPpoVNRnVeDI8qvDZfdeMh34qfGW9fHUpMXeNUCoTSORu8IRbka5cW3UR/+K4DES5CQYMHZy7M+BAYwEYQ== X-OriginatorOrg: outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: 2c1a0e8e-f3e3-4813-e5b8-08dc4adde4b9 X-MS-Exchange-CrossTenant-AuthSource: GV1P250MB0737.EURP250.PROD.OUTLOOK.COM X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 23 Mar 2024 02:06:46.7898 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 84df9e7f-e9f6-40af-b435-aaaaaaaaaaaa X-MS-Exchange-CrossTenant-RMS-PersistedConsumerOrg: 00000000-0000-0000-0000-000000000000 X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM8P250MB0137 Subject: [FFmpeg-devel] [PATCH 14/15] avformat/vqf: Return 0 on success in read_packet 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 Cc: Andreas Rheinhardt Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" X-TUID: eVdDIom7toIF Demuxers are not supposed to return the size of the packet read. Signed-off-by: Andreas Rheinhardt --- libavformat/vqf.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libavformat/vqf.c b/libavformat/vqf.c index 4c7f5aa22e..409c014a92 100644 --- a/libavformat/vqf.c +++ b/libavformat/vqf.c @@ -259,7 +259,7 @@ static int vqf_read_packet(AVFormatContext *s, AVPacket *pkt) c->last_frame_bits = pkt->data[size+1]; c->remaining_bits = (size << 3) - c->frame_bit_len + c->remaining_bits; - return size+2; + return 0; } static int vqf_read_seek(AVFormatContext *s, From patchwork Sat Mar 23 02:06:23 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andreas Rheinhardt X-Patchwork-Id: 47347 Delivered-To: ffmpegpatchwork2@gmail.com Received: by 2002:a05:6a21:1014:b0:1a3:ac71:9534 with SMTP id nk20csp286284pzb; Fri, 22 Mar 2024 19:08:36 -0700 (PDT) X-Forwarded-Encrypted: i=2; AJvYcCXeSXDSq/CsZc0Dzc8C2pKoBrzLv6P8Vu5Cd6gfjejnpIXo7dnsRIqkic5vNUJAkaYgj30lYRY0fuu42kN9c6PxftPEB2aM4S44hw== X-Google-Smtp-Source: AGHT+IGIkSTWXk4hm5qVocDcjshUhEDyNoIXOd1o+3wOYQR2fR2SJpcclQaQUOs9wz+7B/BHTwAM X-Received: by 2002:a19:740f:0:b0:513:d884:7aac with SMTP id v15-20020a19740f000000b00513d8847aacmr571522lfe.21.1711159716459; Fri, 22 Mar 2024 19:08:36 -0700 (PDT) Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org. [79.124.17.100]) by mx.google.com with ESMTP id t12-20020a1709060c4c00b00a46ba937b50si397332ejf.830.2024.03.22.19.08.36; Fri, 22 Mar 2024 19:08:36 -0700 (PDT) Received-SPF: pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) client-ip=79.124.17.100; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@outlook.com header.s=selector1 header.b=NRIvI9yJ; arc=fail (body hash mismatch); spf=pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) smtp.mailfrom=ffmpeg-devel-bounces@ffmpeg.org; dmarc=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=outlook.com Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id 8CA8368D612; Sat, 23 Mar 2024 04:07:02 +0200 (EET) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from EUR04-HE1-obe.outbound.protection.outlook.com (mail-he1eur04olkn2090.outbound.protection.outlook.com [40.92.73.90]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id E3D2668D5E3 for ; Sat, 23 Mar 2024 04:06:54 +0200 (EET) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=UPMyNwvRF+Zv6dftmIcXtGoVSpoNs3XNwrtXqiyIePTdLLuR1fwA1pgrKjUGKfTlKmEgdyT5iOL1aqaf2sa4QBcUXFmlfn3kw8IatdVXGPzc9BDDu/NS5NHZZ9TXKXV176kpH8rItQiac51PZOLGheFLlbTjBiZaO2BdZF7uhHZc3G6Lw7ouySG7r+CVt9j1w1pb76StfLWMutnMlKI/pPp7FEPf0/wSnfRyqWsLUBxVnPBMErRo/hreD3rj3w07lEnlSbetk3Cg3voqIC6UWSbm62fJIHTK8U81l8HNHgvvr09uwv7CRDh4rxZtIrVzWpWa80CSayqAI2WZdElhBg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=vKdclnx+gG+DVPD2S2Tt+81cx4Yli9zKRk9yLKEhsKw=; b=hGJKXM2eWhiB4QkPrNVRC6ghzwEfeIu5YlG8IY/LC2Z4EWmLDFKT/57n6X28TS0VbFnR+NSVCB+A9/FD2F+o4keAdS6rptSX75BtLE5RwG8hzTiB8LSjX3aEaeetpzTo2ihAYce02LS1+jUgnZU/0ufQhVPnxXoIEd93SfS9L6Dyce021Skw6EF/k8dKicEe6wV4/MVzyAFcJGS1TqnxY9PIt7rXNHUAwarKqFXj4bvC2nTBLo2aUxXZiTfn4SNJEDKN7qaq3HuOSybFcCzwNpvf2Xixl5d69saBuPa0GxX9pap5L0CIFbbfeNrCh6CkTFvOf2Xbw/T88ePQNGB6Vg== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=none; dmarc=none; dkim=none; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=outlook.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=vKdclnx+gG+DVPD2S2Tt+81cx4Yli9zKRk9yLKEhsKw=; b=NRIvI9yJVN/9u0I5H/3SPH6TRCoIIa6jkevug2+F3yrbltCKtSjsvcAZScaU/IoQbOCXtKPXqVHpRKOYTUp5JLd+Pa+Pebh9uc/PfNyLbmpZd36kjkK9hGnlqE4iycc594jn3iITWL6zwlO/hIipaUK1K39pDt8JhP8qHXfk4k64ba+Yisq3QQ1s06jxUEj0QV3otv9hplHNVT6cYFdsWWdDjMBN2recoSVV7qFwUojoZaimH/dFc/2jgeWNNwtuZikKNdTwkqQDaXGlaInIfHX3F58qaDTYlGm4pDgeETgsxHZhsSr8iKG7rvvyceWJ1HituE7CtXyNd9+F6SHGgw== Received: from GV1P250MB0737.EURP250.PROD.OUTLOOK.COM (2603:10a6:150:8e::17) by AM8P250MB0137.EURP250.PROD.OUTLOOK.COM (2603:10a6:20b:320::11) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7409.24; Sat, 23 Mar 2024 02:06:48 +0000 Received: from GV1P250MB0737.EURP250.PROD.OUTLOOK.COM ([fe80::4a3b:cf76:cddc:c68d]) by GV1P250MB0737.EURP250.PROD.OUTLOOK.COM ([fe80::4a3b:cf76:cddc:c68d%4]) with mapi id 15.20.7386.025; Sat, 23 Mar 2024 02:06:48 +0000 From: Andreas Rheinhardt To: ffmpeg-devel@ffmpeg.org Date: Sat, 23 Mar 2024 03:06:23 +0100 Message-ID: X-Mailer: git-send-email 2.40.1 In-Reply-To: References: X-TMN: [+jwFU8L4atNSeE2Y1IOOIdSVjkEK5yKeZ8Ckl1VYQMw=] X-ClientProxiedBy: ZR0P278CA0005.CHEP278.PROD.OUTLOOK.COM (2603:10a6:910:16::15) To GV1P250MB0737.EURP250.PROD.OUTLOOK.COM (2603:10a6:150:8e::17) X-Microsoft-Original-Message-ID: <20240323020623.1570961-14-andreas.rheinhardt@outlook.com> MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: GV1P250MB0737:EE_|AM8P250MB0137:EE_ X-MS-Office365-Filtering-Correlation-Id: c13337cb-08f2-4512-7941-08d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wyvPhijPIJQ/enBKdEUoN7BKKYHoOgdWy8piB3yjVOgHlLQGoUrtZZ6lCkWozopeKR1a8bx5oYksl1Mg9cSaDx+morzDbVuw9a++ghLAaoKcucICMS4346a16hKmDnh7DIGij04bnbcfUamjRt/G5xjk6gda6oZhJjZkANjGYjOB2/ogKvsOM1YeQ8dH9zHhnoq1RW1kc/pM4CFfYKxr5WY6JuNE2XhywlwCRUvTuLLNHdINsxsf8+O+1HBkHdV2IYe26l7Yub9hq926MUdC3eJBnXHDhGLM0wKoN+5g+kN7GaFhxtlPtEXOIZpWMaii3WWPu4HbSsscNeZYG8qIUuVg4yW723wfgYa78FSTZpnRiPjM7QnIh88QZ/C7qcp+QpZqnwGAt9ROrHYLre52iYrwgdoQvIoS6pa+eVMA1Lu8kegjFLABoka8UxKpCtIwMy73NlW1iSycZPJk0x/1ljhjiquqvRwl0eqxwFToE7yEa27HS547UeRv7/4TsBndL2B2//AFCR9DpfFzVylsaWdcfM3UIAksbm5nzzxrPPCtKBWKiIjhkWmyfSN3eLzwVV4x/faH5d6NqL7uOYxBXLNoDpMzb3CK2Zd5Rx9jmRLwYjnpTqD6ce2pb3/RtnosK137OnbKpPYAqCgAItSuFZLrJS6XmPjqL815UeirE4oj390VsHH+K5U/OQ== X-OriginatorOrg: outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: c13337cb-08f2-4512-7941-08dc4adde57b X-MS-Exchange-CrossTenant-AuthSource: GV1P250MB0737.EURP250.PROD.OUTLOOK.COM X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 23 Mar 2024 02:06:48.1531 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 84df9e7f-e9f6-40af-b435-aaaaaaaaaaaa X-MS-Exchange-CrossTenant-RMS-PersistedConsumerOrg: 00000000-0000-0000-0000-000000000000 X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM8P250MB0137 Subject: [FFmpeg-devel] [PATCH 15/15] avformat/internal: Move FF_FMT_INIT_CLEANUP to demux.h 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 Cc: Andreas Rheinhardt Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" X-TUID: B5k2EVdirBy2 and rename it to FF_INFMT_INIT_CLEANUP. This flag is demuxer-only, so this is the more appropriate place for it. This does not preclude adding internal flags common to both demuxer and muxer in the future. Signed-off-by: Andreas Rheinhardt --- libavdevice/lavfi.c | 2 +- libavformat/4xm.c | 2 +- libavformat/aadec.c | 2 +- libavformat/aaxdec.c | 2 +- libavformat/ape.c | 2 +- libavformat/aqtitledec.c | 2 +- libavformat/assdec.c | 2 +- libavformat/av1dec.c | 4 ++-- libavformat/avidec.c | 2 +- libavformat/brstm.c | 4 ++-- libavformat/concatdec.c | 2 +- libavformat/dashdec.c | 2 +- libavformat/demux.c | 2 +- libavformat/demux.h | 8 +++++++- libavformat/dvdvideodec.c | 2 +- libavformat/evcdec.c | 2 +- libavformat/hls.c | 2 +- libavformat/iamfdec.c | 2 +- libavformat/icodec.c | 2 +- libavformat/imfdec.c | 2 +- libavformat/internal.h | 6 ------ libavformat/jacosubdec.c | 2 +- libavformat/jpegxl_anim_dec.c | 2 +- libavformat/jvdec.c | 2 +- libavformat/lafdec.c | 2 +- libavformat/libgme.c | 2 +- libavformat/libopenmpt.c | 2 +- libavformat/lrcdec.c | 2 +- libavformat/matroskadec.c | 4 ++-- libavformat/mccdec.c | 2 +- libavformat/microdvddec.c | 2 +- libavformat/mlvdec.c | 2 +- libavformat/moflex.c | 2 +- libavformat/mov.c | 2 +- libavformat/mpeg.c | 2 +- libavformat/mpl2dec.c | 2 +- libavformat/mpsubdec.c | 2 +- libavformat/mxfdec.c | 2 +- libavformat/nsvdec.c | 2 +- libavformat/nutdec.c | 2 +- libavformat/oggdec.c | 2 +- libavformat/omadec.c | 2 +- libavformat/paf.c | 2 +- libavformat/pdvdec.c | 2 +- libavformat/pjsdec.c | 2 +- libavformat/pp_bnk.c | 2 +- libavformat/realtextdec.c | 2 +- libavformat/rmdec.c | 4 ++-- libavformat/samidec.c | 2 +- libavformat/sccdec.c | 2 +- libavformat/scd.c | 2 +- libavformat/segafilm.c | 2 +- libavformat/sierravmd.c | 2 +- libavformat/srtdec.c | 2 +- libavformat/stldec.c | 2 +- libavformat/subviewer1dec.c | 2 +- libavformat/subviewerdec.c | 2 +- libavformat/tedcaptionsdec.c | 2 +- libavformat/tiertexseq.c | 2 +- libavformat/vapoursynth.c | 2 +- libavformat/vividas.c | 2 +- libavformat/vplayerdec.c | 2 +- libavformat/wc3movie.c | 2 +- libavformat/webvttdec.c | 2 +- libavformat/xmv.c | 2 +- 65 files changed, 74 insertions(+), 74 deletions(-) diff --git a/libavdevice/lavfi.c b/libavdevice/lavfi.c index 58ad62bd97..ce10d61f8a 100644 --- a/libavdevice/lavfi.c +++ b/libavdevice/lavfi.c @@ -503,5 +503,5 @@ const FFInputFormat ff_lavfi_demuxer = { .read_header = lavfi_read_header, .read_packet = lavfi_read_packet, .read_close = lavfi_read_close, - .flags_internal = FF_FMT_INIT_CLEANUP, + .flags_internal = FF_INFMT_FLAG_INIT_CLEANUP, }; diff --git a/libavformat/4xm.c b/libavformat/4xm.c index 3424791b81..516c7866bd 100644 --- a/libavformat/4xm.c +++ b/libavformat/4xm.c @@ -401,7 +401,7 @@ const FFInputFormat ff_fourxm_demuxer = { .p.name = "4xm", .p.long_name = NULL_IF_CONFIG_SMALL("4X Technologies"), .priv_data_size = sizeof(FourxmDemuxContext), - .flags_internal = FF_FMT_INIT_CLEANUP, + .flags_internal = FF_INFMT_FLAG_INIT_CLEANUP, .read_probe = fourxm_probe, .read_header = fourxm_read_header, .read_packet = fourxm_read_packet, diff --git a/libavformat/aadec.c b/libavformat/aadec.c index dd698d0d5d..c39fb51a8d 100644 --- a/libavformat/aadec.c +++ b/libavformat/aadec.c @@ -383,5 +383,5 @@ const FFInputFormat ff_aa_demuxer = { .read_packet = aa_read_packet, .read_seek = aa_read_seek, .read_close = aa_read_close, - .flags_internal = FF_FMT_INIT_CLEANUP, + .flags_internal = FF_INFMT_FLAG_INIT_CLEANUP, }; diff --git a/libavformat/aaxdec.c b/libavformat/aaxdec.c index 0ccd4944db..830ae5d89e 100644 --- a/libavformat/aaxdec.c +++ b/libavformat/aaxdec.c @@ -389,7 +389,7 @@ const FFInputFormat ff_aax_demuxer = { .p.extensions = "aax", .p.flags = AVFMT_GENERIC_INDEX, .priv_data_size = sizeof(AAXContext), - .flags_internal = FF_FMT_INIT_CLEANUP, + .flags_internal = FF_INFMT_FLAG_INIT_CLEANUP, .read_probe = aax_probe, .read_header = aax_read_header, .read_packet = aax_read_packet, diff --git a/libavformat/ape.c b/libavformat/ape.c index b3994d12fd..231064be61 100644 --- a/libavformat/ape.c +++ b/libavformat/ape.c @@ -450,7 +450,7 @@ const FFInputFormat ff_ape_demuxer = { .p.long_name = NULL_IF_CONFIG_SMALL("Monkey's Audio"), .p.extensions = "ape,apl,mac", .priv_data_size = sizeof(APEContext), - .flags_internal = FF_FMT_INIT_CLEANUP, + .flags_internal = FF_INFMT_FLAG_INIT_CLEANUP, .read_probe = ape_probe, .read_header = ape_read_header, .read_packet = ape_read_packet, diff --git a/libavformat/aqtitledec.c b/libavformat/aqtitledec.c index e8e538e414..5d41a2278d 100644 --- a/libavformat/aqtitledec.c +++ b/libavformat/aqtitledec.c @@ -142,7 +142,7 @@ const FFInputFormat ff_aqtitle_demuxer = { .p.extensions = "aqt", .p.priv_class = &aqt_class, .priv_data_size = sizeof(AQTitleContext), - .flags_internal = FF_FMT_INIT_CLEANUP, + .flags_internal = FF_INFMT_FLAG_INIT_CLEANUP, .read_probe = aqt_probe, .read_header = aqt_read_header, .read_packet = aqt_read_packet, diff --git a/libavformat/assdec.c b/libavformat/assdec.c index a689a59689..3a8353f4d3 100644 --- a/libavformat/assdec.c +++ b/libavformat/assdec.c @@ -164,7 +164,7 @@ end: const FFInputFormat ff_ass_demuxer = { .p.name = "ass", .p.long_name = NULL_IF_CONFIG_SMALL("SSA (SubStation Alpha) subtitle"), - .flags_internal = FF_FMT_INIT_CLEANUP, + .flags_internal = FF_INFMT_FLAG_INIT_CLEANUP, .priv_data_size = sizeof(ASSContext), .read_probe = ass_probe, .read_header = ass_read_header, diff --git a/libavformat/av1dec.c b/libavformat/av1dec.c index 3382613d54..3363003b18 100644 --- a/libavformat/av1dec.c +++ b/libavformat/av1dec.c @@ -289,7 +289,7 @@ const FFInputFormat ff_av1_demuxer = { .p.flags = AVFMT_GENERIC_INDEX | AVFMT_NOTIMESTAMPS, .p.priv_class = &av1_demuxer_class, .priv_data_size = sizeof(AV1DemuxContext), - .flags_internal = FF_FMT_INIT_CLEANUP, + .flags_internal = FF_INFMT_FLAG_INIT_CLEANUP, .read_probe = annexb_probe, .read_header = av1_read_header, .read_packet = annexb_read_packet, @@ -434,7 +434,7 @@ const FFInputFormat ff_obu_demuxer = { .p.flags = AVFMT_GENERIC_INDEX | AVFMT_NO_BYTE_SEEK | AVFMT_NOTIMESTAMPS, .p.priv_class = &av1_demuxer_class, .priv_data_size = sizeof(AV1DemuxContext), - .flags_internal = FF_FMT_INIT_CLEANUP, + .flags_internal = FF_INFMT_FLAG_INIT_CLEANUP, .read_probe = obu_probe, .read_header = av1_read_header, .read_packet = obu_read_packet, diff --git a/libavformat/avidec.c b/libavformat/avidec.c index 985a9bf022..4635d25d9a 100644 --- a/libavformat/avidec.c +++ b/libavformat/avidec.c @@ -2016,7 +2016,7 @@ const FFInputFormat ff_avi_demuxer = { .p.extensions = "avi", .p.priv_class = &demuxer_class, .priv_data_size = sizeof(AVIContext), - .flags_internal = FF_FMT_INIT_CLEANUP, + .flags_internal = FF_INFMT_FLAG_INIT_CLEANUP, .read_probe = avi_probe, .read_header = avi_read_header, .read_packet = avi_read_packet, diff --git a/libavformat/brstm.c b/libavformat/brstm.c index 5b2a59b6eb..8b0ba3af67 100644 --- a/libavformat/brstm.c +++ b/libavformat/brstm.c @@ -472,7 +472,7 @@ const FFInputFormat ff_brstm_demuxer = { .p.long_name = NULL_IF_CONFIG_SMALL("BRSTM (Binary Revolution Stream)"), .p.extensions = "brstm", .priv_data_size = sizeof(BRSTMDemuxContext), - .flags_internal = FF_FMT_INIT_CLEANUP, + .flags_internal = FF_INFMT_FLAG_INIT_CLEANUP, .read_probe = probe, .read_header = read_header, .read_packet = read_packet, @@ -485,7 +485,7 @@ const FFInputFormat ff_bfstm_demuxer = { .p.long_name = NULL_IF_CONFIG_SMALL("BFSTM (Binary Cafe Stream)"), .p.extensions = "bfstm,bcstm", .priv_data_size = sizeof(BRSTMDemuxContext), - .flags_internal = FF_FMT_INIT_CLEANUP, + .flags_internal = FF_INFMT_FLAG_INIT_CLEANUP, .read_probe = probe_bfstm, .read_header = read_header, .read_packet = read_packet, diff --git a/libavformat/concatdec.c b/libavformat/concatdec.c index ac541a592f..6cb5b9ee24 100644 --- a/libavformat/concatdec.c +++ b/libavformat/concatdec.c @@ -947,7 +947,7 @@ const FFInputFormat ff_concat_demuxer = { .p.long_name = NULL_IF_CONFIG_SMALL("Virtual concatenation script"), .p.priv_class = &concat_class, .priv_data_size = sizeof(ConcatContext), - .flags_internal = FF_FMT_INIT_CLEANUP, + .flags_internal = FF_INFMT_FLAG_INIT_CLEANUP, .read_probe = concat_probe, .read_header = concat_read_header, .read_packet = concat_read_packet, diff --git a/libavformat/dashdec.c b/libavformat/dashdec.c index 2998bcfb48..63070b77be 100644 --- a/libavformat/dashdec.c +++ b/libavformat/dashdec.c @@ -2361,7 +2361,7 @@ const FFInputFormat ff_dash_demuxer = { .p.priv_class = &dash_class, .p.flags = AVFMT_NO_BYTE_SEEK, .priv_data_size = sizeof(DASHContext), - .flags_internal = FF_FMT_INIT_CLEANUP, + .flags_internal = FF_INFMT_FLAG_INIT_CLEANUP, .read_probe = dash_probe, .read_header = dash_read_header, .read_packet = dash_read_packet, diff --git a/libavformat/demux.c b/libavformat/demux.c index 4c50eb5568..79c5ebd4ca 100644 --- a/libavformat/demux.c +++ b/libavformat/demux.c @@ -302,7 +302,7 @@ int avformat_open_input(AVFormatContext **ps, const char *filename, if (ffifmt(s->iformat)->read_header) if ((ret = ffifmt(s->iformat)->read_header(s)) < 0) { - if (ffifmt(s->iformat)->flags_internal & FF_FMT_INIT_CLEANUP) + if (ffifmt(s->iformat)->flags_internal & FF_INFMT_FLAG_INIT_CLEANUP) goto close; goto fail; } diff --git a/libavformat/demux.h b/libavformat/demux.h index 48c71ab55d..9c76095662 100644 --- a/libavformat/demux.h +++ b/libavformat/demux.h @@ -28,6 +28,12 @@ struct AVDeviceInfoList; +/** + * For an FFInputFormat with this flag set read_close() needs to be called + * by the caller upon read_header() failure. + */ +#define FF_INFMT_FLAG_INIT_CLEANUP (1 << 0) + typedef struct FFInputFormat { /** * The public AVInputFormat. See avformat.h for it. @@ -45,7 +51,7 @@ typedef struct FFInputFormat { int priv_data_size; /** - * Internal flags. See FF_FMT_FLAG_* in internal.h. + * Internal flags. See FF_INFMT_FLAG_* above and FF_FMT_FLAG_* in internal.h. */ int flags_internal; diff --git a/libavformat/dvdvideodec.c b/libavformat/dvdvideodec.c index 761ac97ec6..8acbe5a1a1 100644 --- a/libavformat/dvdvideodec.c +++ b/libavformat/dvdvideodec.c @@ -1705,7 +1705,7 @@ const FFInputFormat ff_dvdvideo_demuxer = { .p.flags = AVFMT_NOFILE | AVFMT_SHOW_IDS | AVFMT_TS_DISCONT | AVFMT_NO_BYTE_SEEK | AVFMT_NOGENSEARCH | AVFMT_NOBINSEARCH, .priv_data_size = sizeof(DVDVideoDemuxContext), - .flags_internal = FF_FMT_INIT_CLEANUP, + .flags_internal = FF_INFMT_FLAG_INIT_CLEANUP, .read_close = dvdvideo_close, .read_header = dvdvideo_read_header, .read_packet = dvdvideo_read_packet diff --git a/libavformat/evcdec.c b/libavformat/evcdec.c index 5e565809ec..9e735fab55 100644 --- a/libavformat/evcdec.c +++ b/libavformat/evcdec.c @@ -212,7 +212,7 @@ const FFInputFormat ff_evc_demuxer = { .read_header = evc_read_header, // annexb_read_header .read_packet = evc_read_packet, // annexb_read_packet .read_close = evc_read_close, - .flags_internal = FF_FMT_INIT_CLEANUP, + .flags_internal = FF_INFMT_FLAG_INIT_CLEANUP, .raw_codec_id = AV_CODEC_ID_EVC, .priv_data_size = sizeof(EVCDemuxContext), }; diff --git a/libavformat/hls.c b/libavformat/hls.c index 94defa9384..8702113e9f 100644 --- a/libavformat/hls.c +++ b/libavformat/hls.c @@ -2602,7 +2602,7 @@ const FFInputFormat ff_hls_demuxer = { .p.priv_class = &hls_class, .p.flags = AVFMT_NOGENSEARCH | AVFMT_TS_DISCONT | AVFMT_NO_BYTE_SEEK, .priv_data_size = sizeof(HLSContext), - .flags_internal = FF_FMT_INIT_CLEANUP, + .flags_internal = FF_INFMT_FLAG_INIT_CLEANUP, .read_probe = hls_probe, .read_header = hls_read_header, .read_packet = hls_read_packet, diff --git a/libavformat/iamfdec.c b/libavformat/iamfdec.c index fc1af82034..e34d13e74c 100644 --- a/libavformat/iamfdec.c +++ b/libavformat/iamfdec.c @@ -184,7 +184,7 @@ const FFInputFormat ff_iamf_demuxer = { .p.extensions = "iamf", .p.flags = AVFMT_GENERIC_INDEX | AVFMT_NO_BYTE_SEEK | AVFMT_NOTIMESTAMPS | AVFMT_SHOW_IDS, .priv_data_size = sizeof(IAMFDemuxContext), - .flags_internal = FF_FMT_INIT_CLEANUP, + .flags_internal = FF_INFMT_FLAG_INIT_CLEANUP, .read_probe = iamf_probe, .read_header = iamf_read_header, .read_packet = iamf_read_packet, diff --git a/libavformat/icodec.c b/libavformat/icodec.c index 0ec6e0b258..808c7ab795 100644 --- a/libavformat/icodec.c +++ b/libavformat/icodec.c @@ -222,7 +222,7 @@ const FFInputFormat ff_ico_demuxer = { .p.long_name = NULL_IF_CONFIG_SMALL("Microsoft Windows ICO"), .p.flags = AVFMT_NOTIMESTAMPS, .priv_data_size = sizeof(IcoDemuxContext), - .flags_internal = FF_FMT_INIT_CLEANUP, + .flags_internal = FF_INFMT_FLAG_INIT_CLEANUP, .read_probe = probe, .read_header = read_header, .read_packet = read_packet, diff --git a/libavformat/imfdec.c b/libavformat/imfdec.c index b57c54bd14..4625d720ac 100644 --- a/libavformat/imfdec.c +++ b/libavformat/imfdec.c @@ -1019,7 +1019,7 @@ const FFInputFormat ff_imf_demuxer = { .p.long_name = NULL_IF_CONFIG_SMALL("IMF (Interoperable Master Format)"), .p.flags = AVFMT_NO_BYTE_SEEK, .p.priv_class = &imf_class, - .flags_internal = FF_FMT_INIT_CLEANUP, + .flags_internal = FF_INFMT_FLAG_INIT_CLEANUP, .priv_data_size = sizeof(IMFContext), .read_probe = imf_probe, .read_header = imf_read_header, diff --git a/libavformat/internal.h b/libavformat/internal.h index e5f8337130..7f3d1c0086 100644 --- a/libavformat/internal.h +++ b/libavformat/internal.h @@ -39,12 +39,6 @@ # define hex_dump_debug(class, buf, size) do { if (0) av_hex_dump_log(class, AV_LOG_DEBUG, buf, size); } while(0) #endif -/** - * For an FFInputFormat with this flag set read_close() needs to be called - * by the caller upon read_header() failure. - */ -#define FF_FMT_INIT_CLEANUP (1 << 0) - typedef struct AVCodecTag { enum AVCodecID id; unsigned int tag; diff --git a/libavformat/jacosubdec.c b/libavformat/jacosubdec.c index 8b0aa312fc..f383d44deb 100644 --- a/libavformat/jacosubdec.c +++ b/libavformat/jacosubdec.c @@ -261,7 +261,7 @@ const FFInputFormat ff_jacosub_demuxer = { .p.name = "jacosub", .p.long_name = NULL_IF_CONFIG_SMALL("JACOsub subtitle format"), .priv_data_size = sizeof(JACOsubContext), - .flags_internal = FF_FMT_INIT_CLEANUP, + .flags_internal = FF_INFMT_FLAG_INIT_CLEANUP, .read_probe = jacosub_probe, .read_header = jacosub_read_header, .read_packet = ff_subtitles_read_packet, diff --git a/libavformat/jpegxl_anim_dec.c b/libavformat/jpegxl_anim_dec.c index f749b378b3..6af83825ea 100644 --- a/libavformat/jpegxl_anim_dec.c +++ b/libavformat/jpegxl_anim_dec.c @@ -200,5 +200,5 @@ const FFInputFormat ff_jpegxl_anim_demuxer = { .read_header = jpegxl_anim_read_header, .read_packet = jpegxl_anim_read_packet, .read_close = jpegxl_anim_close, - .flags_internal = FF_FMT_INIT_CLEANUP, + .flags_internal = FF_INFMT_FLAG_INIT_CLEANUP, }; diff --git a/libavformat/jvdec.c b/libavformat/jvdec.c index 89c82483aa..41dad2392f 100644 --- a/libavformat/jvdec.c +++ b/libavformat/jvdec.c @@ -255,7 +255,7 @@ const FFInputFormat ff_jv_demuxer = { .p.name = "jv", .p.long_name = NULL_IF_CONFIG_SMALL("Bitmap Brothers JV"), .priv_data_size = sizeof(JVDemuxContext), - .flags_internal = FF_FMT_INIT_CLEANUP, + .flags_internal = FF_INFMT_FLAG_INIT_CLEANUP, .read_probe = read_probe, .read_header = read_header, .read_packet = read_packet, diff --git a/libavformat/lafdec.c b/libavformat/lafdec.c index 77eab2ea6b..4ce4449c4e 100644 --- a/libavformat/lafdec.c +++ b/libavformat/lafdec.c @@ -289,5 +289,5 @@ const FFInputFormat ff_laf_demuxer = { .read_packet = laf_read_packet, .read_close = laf_read_close, .read_seek = laf_read_seek, - .flags_internal = FF_FMT_INIT_CLEANUP, + .flags_internal = FF_INFMT_FLAG_INIT_CLEANUP, }; diff --git a/libavformat/libgme.c b/libavformat/libgme.c index c2baa9c3ff..26d079c270 100644 --- a/libavformat/libgme.c +++ b/libavformat/libgme.c @@ -199,7 +199,7 @@ const FFInputFormat ff_libgme_demuxer = { .p.long_name = NULL_IF_CONFIG_SMALL("Game Music Emu demuxer"), .p.priv_class = &class_gme, .priv_data_size = sizeof(GMEContext), - .flags_internal = FF_FMT_INIT_CLEANUP, + .flags_internal = FF_INFMT_FLAG_INIT_CLEANUP, .read_probe = probe_gme, .read_header = read_header_gme, .read_packet = read_packet_gme, diff --git a/libavformat/libopenmpt.c b/libavformat/libopenmpt.c index 1fab0f09d8..c270a60cb2 100644 --- a/libavformat/libopenmpt.c +++ b/libavformat/libopenmpt.c @@ -289,7 +289,7 @@ const FFInputFormat ff_libopenmpt_demuxer = { .p.extensions = "669,amf,ams,dbm,digi,dmf,dsm,far,gdm,ice,imf,it,j2b,m15,mdl,med,mmcmp,mms,mo3,mod,mptm,mt2,mtm,nst,okt,plm,ppm,psm,pt36,ptm,s3m,sfx,sfx2,st26,stk,stm,ult,umx,wow,xm,xpk", #endif .priv_data_size = sizeof(OpenMPTContext), - .flags_internal = FF_FMT_INIT_CLEANUP, + .flags_internal = FF_INFMT_FLAG_INIT_CLEANUP, .read_probe = read_probe_openmpt, .read_header = read_header_openmpt, .read_packet = read_packet_openmpt, diff --git a/libavformat/lrcdec.c b/libavformat/lrcdec.c index 216bcc42eb..5435a65b15 100644 --- a/libavformat/lrcdec.c +++ b/libavformat/lrcdec.c @@ -229,7 +229,7 @@ const FFInputFormat ff_lrc_demuxer = { .p.name = "lrc", .p.long_name = NULL_IF_CONFIG_SMALL("LRC lyrics"), .priv_data_size = sizeof (LRCContext), - .flags_internal = FF_FMT_INIT_CLEANUP, + .flags_internal = FF_INFMT_FLAG_INIT_CLEANUP, .read_probe = lrc_probe, .read_header = lrc_read_header, .read_packet = ff_subtitles_read_packet, diff --git a/libavformat/matroskadec.c b/libavformat/matroskadec.c index 8897fd622c..e724e50a8e 100644 --- a/libavformat/matroskadec.c +++ b/libavformat/matroskadec.c @@ -4792,7 +4792,7 @@ const FFInputFormat ff_webm_dash_manifest_demuxer = { .p.long_name = NULL_IF_CONFIG_SMALL("WebM DASH Manifest"), .p.priv_class = &webm_dash_class, .priv_data_size = sizeof(MatroskaDemuxContext), - .flags_internal = FF_FMT_INIT_CLEANUP, + .flags_internal = FF_INFMT_FLAG_INIT_CLEANUP, .read_header = webm_dash_manifest_read_header, .read_packet = webm_dash_manifest_read_packet, .read_close = matroska_read_close, @@ -4805,7 +4805,7 @@ const FFInputFormat ff_matroska_demuxer = { .p.extensions = "mkv,mk3d,mka,mks,webm", .p.mime_type = "audio/webm,audio/x-matroska,video/webm,video/x-matroska", .priv_data_size = sizeof(MatroskaDemuxContext), - .flags_internal = FF_FMT_INIT_CLEANUP, + .flags_internal = FF_INFMT_FLAG_INIT_CLEANUP, .read_probe = matroska_probe, .read_header = matroska_read_header, .read_packet = matroska_read_packet, diff --git a/libavformat/mccdec.c b/libavformat/mccdec.c index d20724b879..85bf93cd3b 100644 --- a/libavformat/mccdec.c +++ b/libavformat/mccdec.c @@ -206,7 +206,7 @@ const FFInputFormat ff_mcc_demuxer = { .p.long_name = NULL_IF_CONFIG_SMALL("MacCaption"), .p.extensions = "mcc", .priv_data_size = sizeof(MCCContext), - .flags_internal = FF_FMT_INIT_CLEANUP, + .flags_internal = FF_INFMT_FLAG_INIT_CLEANUP, .read_probe = mcc_probe, .read_header = mcc_read_header, .read_packet = ff_subtitles_read_packet, diff --git a/libavformat/microdvddec.c b/libavformat/microdvddec.c index 8660c43ef9..001f1cec15 100644 --- a/libavformat/microdvddec.c +++ b/libavformat/microdvddec.c @@ -204,7 +204,7 @@ const FFInputFormat ff_microdvd_demuxer = { .p.long_name = NULL_IF_CONFIG_SMALL("MicroDVD subtitle format"), .p.priv_class = µdvd_class, .priv_data_size = sizeof(MicroDVDContext), - .flags_internal = FF_FMT_INIT_CLEANUP, + .flags_internal = FF_INFMT_FLAG_INIT_CLEANUP, .read_probe = microdvd_probe, .read_header = microdvd_read_header, .read_packet = microdvd_read_packet, diff --git a/libavformat/mlvdec.c b/libavformat/mlvdec.c index b969a45550..e3165e3811 100644 --- a/libavformat/mlvdec.c +++ b/libavformat/mlvdec.c @@ -492,7 +492,7 @@ const FFInputFormat ff_mlv_demuxer = { .p.name = "mlv", .p.long_name = NULL_IF_CONFIG_SMALL("Magic Lantern Video (MLV)"), .priv_data_size = sizeof(MlvContext), - .flags_internal = FF_FMT_INIT_CLEANUP, + .flags_internal = FF_INFMT_FLAG_INIT_CLEANUP, .read_probe = probe, .read_header = read_header, .read_packet = read_packet, diff --git a/libavformat/moflex.c b/libavformat/moflex.c index 44fdaf3269..85511a04be 100644 --- a/libavformat/moflex.c +++ b/libavformat/moflex.c @@ -383,5 +383,5 @@ const FFInputFormat ff_moflex_demuxer = { .read_packet = moflex_read_packet, .read_seek = moflex_read_seek, .read_close = moflex_read_close, - .flags_internal = FF_FMT_INIT_CLEANUP, + .flags_internal = FF_INFMT_FLAG_INIT_CLEANUP, }; diff --git a/libavformat/mov.c b/libavformat/mov.c index 8d1135270c..610b699d38 100644 --- a/libavformat/mov.c +++ b/libavformat/mov.c @@ -10309,7 +10309,7 @@ const FFInputFormat ff_mov_demuxer = { .p.extensions = "mov,mp4,m4a,3gp,3g2,mj2,psp,m4b,ism,ismv,isma,f4v,avif,heic,heif", .p.flags = AVFMT_NO_BYTE_SEEK | AVFMT_SEEK_TO_PTS | AVFMT_SHOW_IDS, .priv_data_size = sizeof(MOVContext), - .flags_internal = FF_FMT_INIT_CLEANUP, + .flags_internal = FF_INFMT_FLAG_INIT_CLEANUP, .read_probe = mov_probe, .read_header = mov_read_header, .read_packet = mov_read_packet, diff --git a/libavformat/mpeg.c b/libavformat/mpeg.c index 8399ad7062..904a79d9a7 100644 --- a/libavformat/mpeg.c +++ b/libavformat/mpeg.c @@ -1055,7 +1055,7 @@ const FFInputFormat ff_vobsub_demuxer = { .p.extensions = "idx", .p.priv_class = &vobsub_demuxer_class, .priv_data_size = sizeof(VobSubDemuxContext), - .flags_internal = FF_FMT_INIT_CLEANUP, + .flags_internal = FF_INFMT_FLAG_INIT_CLEANUP, .read_probe = vobsub_probe, .read_header = vobsub_read_header, .read_packet = vobsub_read_packet, diff --git a/libavformat/mpl2dec.c b/libavformat/mpl2dec.c index 6c3dba2d8f..9daf51ff86 100644 --- a/libavformat/mpl2dec.c +++ b/libavformat/mpl2dec.c @@ -128,7 +128,7 @@ const FFInputFormat ff_mpl2_demuxer = { .p.long_name = NULL_IF_CONFIG_SMALL("MPL2 subtitles"), .p.extensions = "txt,mpl2", .priv_data_size = sizeof(MPL2Context), - .flags_internal = FF_FMT_INIT_CLEANUP, + .flags_internal = FF_INFMT_FLAG_INIT_CLEANUP, .read_probe = mpl2_probe, .read_header = mpl2_read_header, .read_packet = ff_subtitles_read_packet, diff --git a/libavformat/mpsubdec.c b/libavformat/mpsubdec.c index b5abe296f1..a7fcdab05e 100644 --- a/libavformat/mpsubdec.c +++ b/libavformat/mpsubdec.c @@ -176,7 +176,7 @@ const FFInputFormat ff_mpsub_demuxer = { .p.long_name = NULL_IF_CONFIG_SMALL("MPlayer subtitles"), .p.extensions = "sub", .priv_data_size = sizeof(MPSubContext), - .flags_internal = FF_FMT_INIT_CLEANUP, + .flags_internal = FF_INFMT_FLAG_INIT_CLEANUP, .read_probe = mpsub_probe, .read_header = mpsub_read_header, .read_packet = ff_subtitles_read_packet, diff --git a/libavformat/mxfdec.c b/libavformat/mxfdec.c index 558a6c3b0a..c9af462855 100644 --- a/libavformat/mxfdec.c +++ b/libavformat/mxfdec.c @@ -4265,7 +4265,7 @@ const FFInputFormat ff_mxf_demuxer = { .p.flags = AVFMT_SEEK_TO_PTS, .p.priv_class = &demuxer_class, .priv_data_size = sizeof(MXFContext), - .flags_internal = FF_FMT_INIT_CLEANUP, + .flags_internal = FF_INFMT_FLAG_INIT_CLEANUP, .read_probe = mxf_probe, .read_header = mxf_read_header, .read_packet = mxf_read_packet, diff --git a/libavformat/nsvdec.c b/libavformat/nsvdec.c index d6a39730cc..112c21fc8e 100644 --- a/libavformat/nsvdec.c +++ b/libavformat/nsvdec.c @@ -752,7 +752,7 @@ const FFInputFormat ff_nsv_demuxer = { .p.name = "nsv", .p.long_name = NULL_IF_CONFIG_SMALL("Nullsoft Streaming Video"), .priv_data_size = sizeof(NSVContext), - .flags_internal = FF_FMT_INIT_CLEANUP, + .flags_internal = FF_INFMT_FLAG_INIT_CLEANUP, .read_probe = nsv_probe, .read_header = nsv_read_header, .read_packet = nsv_read_packet, diff --git a/libavformat/nutdec.c b/libavformat/nutdec.c index 670964fab3..8c9b19eebb 100644 --- a/libavformat/nutdec.c +++ b/libavformat/nutdec.c @@ -1313,7 +1313,7 @@ const FFInputFormat ff_nut_demuxer = { .p.extensions = "nut", .p.codec_tag = ff_nut_codec_tags, .priv_data_size = sizeof(NUTContext), - .flags_internal = FF_FMT_INIT_CLEANUP, + .flags_internal = FF_INFMT_FLAG_INIT_CLEANUP, .read_probe = nut_probe, .read_header = nut_read_header, .read_packet = nut_read_packet, diff --git a/libavformat/oggdec.c b/libavformat/oggdec.c index e473683aeb..6efcadd11c 100644 --- a/libavformat/oggdec.c +++ b/libavformat/oggdec.c @@ -966,7 +966,7 @@ const FFInputFormat ff_ogg_demuxer = { .p.extensions = "ogg", .p.flags = AVFMT_GENERIC_INDEX | AVFMT_TS_DISCONT | AVFMT_NOBINSEARCH, .priv_data_size = sizeof(struct ogg), - .flags_internal = FF_FMT_INIT_CLEANUP, + .flags_internal = FF_INFMT_FLAG_INIT_CLEANUP, .read_probe = ogg_probe, .read_header = ogg_read_header, .read_packet = ogg_read_packet, diff --git a/libavformat/omadec.c b/libavformat/omadec.c index f4bd6fb964..2ca3f45b4c 100644 --- a/libavformat/omadec.c +++ b/libavformat/omadec.c @@ -615,7 +615,7 @@ const FFInputFormat ff_oma_demuxer = { .p.extensions = "oma,omg,aa3", .p.codec_tag = ff_oma_codec_tags_list, .priv_data_size = sizeof(OMAContext), - .flags_internal = FF_FMT_INIT_CLEANUP, + .flags_internal = FF_INFMT_FLAG_INIT_CLEANUP, .read_probe = oma_read_probe, .read_header = oma_read_header, .read_packet = oma_read_packet, diff --git a/libavformat/paf.c b/libavformat/paf.c index c99acbd3e7..056cc6e786 100644 --- a/libavformat/paf.c +++ b/libavformat/paf.c @@ -270,7 +270,7 @@ const FFInputFormat ff_paf_demuxer = { .p.name = "paf", .p.long_name = NULL_IF_CONFIG_SMALL("Amazing Studio Packed Animation File"), .priv_data_size = sizeof(PAFDemuxContext), - .flags_internal = FF_FMT_INIT_CLEANUP, + .flags_internal = FF_INFMT_FLAG_INIT_CLEANUP, .read_probe = read_probe, .read_header = read_header, .read_packet = read_packet, diff --git a/libavformat/pdvdec.c b/libavformat/pdvdec.c index 79e09bd9d4..8ed4e20e6b 100644 --- a/libavformat/pdvdec.c +++ b/libavformat/pdvdec.c @@ -165,7 +165,7 @@ const FFInputFormat ff_pdv_demuxer = { .p.long_name = NULL_IF_CONFIG_SMALL("PlayDate Video"), .p.extensions = "pdv", .priv_data_size = sizeof(PDVDemuxContext), - .flags_internal = FF_FMT_INIT_CLEANUP, + .flags_internal = FF_INFMT_FLAG_INIT_CLEANUP, .read_probe = pdv_probe, .read_header = pdv_read_header, .read_packet = pdv_read_packet, diff --git a/libavformat/pjsdec.c b/libavformat/pjsdec.c index 22ddea3596..76e029b29f 100644 --- a/libavformat/pjsdec.c +++ b/libavformat/pjsdec.c @@ -111,7 +111,7 @@ const FFInputFormat ff_pjs_demuxer = { .p.long_name = NULL_IF_CONFIG_SMALL("PJS (Phoenix Japanimation Society) subtitles"), .p.extensions = "pjs", .priv_data_size = sizeof(PJSContext), - .flags_internal = FF_FMT_INIT_CLEANUP, + .flags_internal = FF_INFMT_FLAG_INIT_CLEANUP, .read_probe = pjs_probe, .read_header = pjs_read_header, .read_packet = ff_subtitles_read_packet, diff --git a/libavformat/pp_bnk.c b/libavformat/pp_bnk.c index d545694bef..34156dd717 100644 --- a/libavformat/pp_bnk.c +++ b/libavformat/pp_bnk.c @@ -320,7 +320,7 @@ const FFInputFormat ff_pp_bnk_demuxer = { .p.name = "pp_bnk", .p.long_name = NULL_IF_CONFIG_SMALL("Pro Pinball Series Soundbank"), .priv_data_size = sizeof(PPBnkCtx), - .flags_internal = FF_FMT_INIT_CLEANUP, + .flags_internal = FF_INFMT_FLAG_INIT_CLEANUP, .read_probe = pp_bnk_probe, .read_header = pp_bnk_read_header, .read_packet = pp_bnk_read_packet, diff --git a/libavformat/realtextdec.c b/libavformat/realtextdec.c index 713e174b92..ccf87e9375 100644 --- a/libavformat/realtextdec.c +++ b/libavformat/realtextdec.c @@ -137,7 +137,7 @@ const FFInputFormat ff_realtext_demuxer = { .p.long_name = NULL_IF_CONFIG_SMALL("RealText subtitle format"), .p.extensions = "rt", .priv_data_size = sizeof(RealTextContext), - .flags_internal = FF_FMT_INIT_CLEANUP, + .flags_internal = FF_INFMT_FLAG_INIT_CLEANUP, .read_probe = realtext_probe, .read_header = realtext_read_header, .read_packet = ff_subtitles_read_packet, diff --git a/libavformat/rmdec.c b/libavformat/rmdec.c index ded194bddd..2e75aba2a6 100644 --- a/libavformat/rmdec.c +++ b/libavformat/rmdec.c @@ -1149,7 +1149,7 @@ const FFInputFormat ff_rm_demuxer = { .p.name = "rm", .p.long_name = NULL_IF_CONFIG_SMALL("RealMedia"), .priv_data_size = sizeof(RMDemuxContext), - .flags_internal = FF_FMT_INIT_CLEANUP, + .flags_internal = FF_INFMT_FLAG_INIT_CLEANUP, .read_probe = rm_probe, .read_header = rm_read_header, .read_packet = rm_read_packet, @@ -1403,7 +1403,7 @@ const FFInputFormat ff_ivr_demuxer = { .p.long_name = NULL_IF_CONFIG_SMALL("IVR (Internet Video Recording)"), .p.extensions = "ivr", .priv_data_size = sizeof(RMDemuxContext), - .flags_internal = FF_FMT_INIT_CLEANUP, + .flags_internal = FF_INFMT_FLAG_INIT_CLEANUP, .read_probe = ivr_probe, .read_header = ivr_read_header, .read_packet = ivr_read_packet, diff --git a/libavformat/samidec.c b/libavformat/samidec.c index 4abf7789d1..39e7f4cb8b 100644 --- a/libavformat/samidec.c +++ b/libavformat/samidec.c @@ -127,7 +127,7 @@ const FFInputFormat ff_sami_demuxer = { .p.long_name = NULL_IF_CONFIG_SMALL("SAMI subtitle format"), .p.extensions = "smi,sami", .priv_data_size = sizeof(SAMIContext), - .flags_internal = FF_FMT_INIT_CLEANUP, + .flags_internal = FF_INFMT_FLAG_INIT_CLEANUP, .read_probe = sami_probe, .read_header = sami_read_header, .read_packet = ff_subtitles_read_packet, diff --git a/libavformat/sccdec.c b/libavformat/sccdec.c index f6d5f29a0a..ea05a24533 100644 --- a/libavformat/sccdec.c +++ b/libavformat/sccdec.c @@ -152,7 +152,7 @@ const FFInputFormat ff_scc_demuxer = { .p.long_name = NULL_IF_CONFIG_SMALL("Scenarist Closed Captions"), .p.extensions = "scc", .priv_data_size = sizeof(SCCContext), - .flags_internal = FF_FMT_INIT_CLEANUP, + .flags_internal = FF_INFMT_FLAG_INIT_CLEANUP, .read_probe = scc_probe, .read_header = scc_read_header, .read_packet = ff_subtitles_read_packet, diff --git a/libavformat/scd.c b/libavformat/scd.c index e34d60dcfb..1eef834771 100644 --- a/libavformat/scd.c +++ b/libavformat/scd.c @@ -370,7 +370,7 @@ const FFInputFormat ff_scd_demuxer = { .p.name = "scd", .p.long_name = NULL_IF_CONFIG_SMALL("Square Enix SCD"), .priv_data_size = sizeof(SCDDemuxContext), - .flags_internal = FF_FMT_INIT_CLEANUP, + .flags_internal = FF_INFMT_FLAG_INIT_CLEANUP, .read_probe = scd_probe, .read_header = scd_read_header, .read_packet = scd_read_packet, diff --git a/libavformat/segafilm.c b/libavformat/segafilm.c index 5cbeed6d91..f86845f35e 100644 --- a/libavformat/segafilm.c +++ b/libavformat/segafilm.c @@ -329,7 +329,7 @@ const FFInputFormat ff_segafilm_demuxer = { .p.name = "film_cpk", .p.long_name = NULL_IF_CONFIG_SMALL("Sega FILM / CPK"), .priv_data_size = sizeof(FilmDemuxContext), - .flags_internal = FF_FMT_INIT_CLEANUP, + .flags_internal = FF_INFMT_FLAG_INIT_CLEANUP, .read_probe = film_probe, .read_header = film_read_header, .read_packet = film_read_packet, diff --git a/libavformat/sierravmd.c b/libavformat/sierravmd.c index e7cc4075de..039c6436db 100644 --- a/libavformat/sierravmd.c +++ b/libavformat/sierravmd.c @@ -318,7 +318,7 @@ const FFInputFormat ff_vmd_demuxer = { .p.name = "vmd", .p.long_name = NULL_IF_CONFIG_SMALL("Sierra VMD"), .priv_data_size = sizeof(VmdDemuxContext), - .flags_internal = FF_FMT_INIT_CLEANUP, + .flags_internal = FF_INFMT_FLAG_INIT_CLEANUP, .read_probe = vmd_probe, .read_header = vmd_read_header, .read_packet = vmd_read_packet, diff --git a/libavformat/srtdec.c b/libavformat/srtdec.c index 678796c9dd..6bf73599a7 100644 --- a/libavformat/srtdec.c +++ b/libavformat/srtdec.c @@ -218,7 +218,7 @@ const FFInputFormat ff_srt_demuxer = { .p.name = "srt", .p.long_name = NULL_IF_CONFIG_SMALL("SubRip subtitle"), .priv_data_size = sizeof(SRTContext), - .flags_internal = FF_FMT_INIT_CLEANUP, + .flags_internal = FF_INFMT_FLAG_INIT_CLEANUP, .read_probe = srt_probe, .read_header = srt_read_header, .read_packet = ff_subtitles_read_packet, diff --git a/libavformat/stldec.c b/libavformat/stldec.c index 3b3b113827..dee5e34a62 100644 --- a/libavformat/stldec.c +++ b/libavformat/stldec.c @@ -114,7 +114,7 @@ const FFInputFormat ff_stl_demuxer = { .p.long_name = NULL_IF_CONFIG_SMALL("Spruce subtitle format"), .p.extensions = "stl", .priv_data_size = sizeof(STLContext), - .flags_internal = FF_FMT_INIT_CLEANUP, + .flags_internal = FF_INFMT_FLAG_INIT_CLEANUP, .read_probe = stl_probe, .read_header = stl_read_header, .read_packet = ff_subtitles_read_packet, diff --git a/libavformat/subviewer1dec.c b/libavformat/subviewer1dec.c index 5e7ed729ac..59452d16fc 100644 --- a/libavformat/subviewer1dec.c +++ b/libavformat/subviewer1dec.c @@ -96,7 +96,7 @@ const FFInputFormat ff_subviewer1_demuxer = { .p.long_name = NULL_IF_CONFIG_SMALL("SubViewer v1 subtitle format"), .p.extensions = "sub", .priv_data_size = sizeof(SubViewer1Context), - .flags_internal = FF_FMT_INIT_CLEANUP, + .flags_internal = FF_INFMT_FLAG_INIT_CLEANUP, .read_probe = subviewer1_probe, .read_header = subviewer1_read_header, .read_packet = ff_subtitles_read_packet, diff --git a/libavformat/subviewerdec.c b/libavformat/subviewerdec.c index 1d1d99afa9..a6b8014cb9 100644 --- a/libavformat/subviewerdec.c +++ b/libavformat/subviewerdec.c @@ -191,7 +191,7 @@ const FFInputFormat ff_subviewer_demuxer = { .p.long_name = NULL_IF_CONFIG_SMALL("SubViewer subtitle format"), .p.extensions = "sub", .priv_data_size = sizeof(SubViewerContext), - .flags_internal = FF_FMT_INIT_CLEANUP, + .flags_internal = FF_INFMT_FLAG_INIT_CLEANUP, .read_probe = subviewer_probe, .read_header = subviewer_read_header, .read_packet = ff_subtitles_read_packet, diff --git a/libavformat/tedcaptionsdec.c b/libavformat/tedcaptionsdec.c index 4dbbe5a5b1..ceb6e7f599 100644 --- a/libavformat/tedcaptionsdec.c +++ b/libavformat/tedcaptionsdec.c @@ -361,7 +361,7 @@ const FFInputFormat ff_tedcaptions_demuxer = { .p.long_name = NULL_IF_CONFIG_SMALL("TED Talks captions"), .p.priv_class = &tedcaptions_demuxer_class, .priv_data_size = sizeof(TEDCaptionsDemuxer), - .flags_internal = FF_FMT_INIT_CLEANUP, + .flags_internal = FF_INFMT_FLAG_INIT_CLEANUP, .read_header = tedcaptions_read_header, .read_packet = tedcaptions_read_packet, .read_close = tedcaptions_read_close, diff --git a/libavformat/tiertexseq.c b/libavformat/tiertexseq.c index 9de3689720..86b1023867 100644 --- a/libavformat/tiertexseq.c +++ b/libavformat/tiertexseq.c @@ -312,7 +312,7 @@ const FFInputFormat ff_tiertexseq_demuxer = { .p.name = "tiertexseq", .p.long_name = NULL_IF_CONFIG_SMALL("Tiertex Limited SEQ"), .priv_data_size = sizeof(SeqDemuxContext), - .flags_internal = FF_FMT_INIT_CLEANUP, + .flags_internal = FF_INFMT_FLAG_INIT_CLEANUP, .read_probe = seq_probe, .read_header = seq_read_header, .read_packet = seq_read_packet, diff --git a/libavformat/vapoursynth.c b/libavformat/vapoursynth.c index e300392a8a..b5d80abf30 100644 --- a/libavformat/vapoursynth.c +++ b/libavformat/vapoursynth.c @@ -486,7 +486,7 @@ const FFInputFormat ff_vapoursynth_demuxer = { .p.long_name = NULL_IF_CONFIG_SMALL("VapourSynth demuxer"), .p.priv_class = &class_vs, .priv_data_size = sizeof(VSContext), - .flags_internal = FF_FMT_INIT_CLEANUP, + .flags_internal = FF_INFMT_FLAG_INIT_CLEANUP, .read_probe = probe_vs, .read_header = read_header_vs, .read_packet = read_packet_vs, diff --git a/libavformat/vividas.c b/libavformat/vividas.c index 98bf134f25..ee4048415e 100644 --- a/libavformat/vividas.c +++ b/libavformat/vividas.c @@ -795,7 +795,7 @@ const FFInputFormat ff_vividas_demuxer = { .p.name = "vividas", .p.long_name = NULL_IF_CONFIG_SMALL("Vividas VIV"), .priv_data_size = sizeof(VividasDemuxContext), - .flags_internal = FF_FMT_INIT_CLEANUP, + .flags_internal = FF_INFMT_FLAG_INIT_CLEANUP, .read_probe = viv_probe, .read_header = viv_read_header, .read_packet = viv_read_packet, diff --git a/libavformat/vplayerdec.c b/libavformat/vplayerdec.c index cd6b3d6c3a..a9d84470c6 100644 --- a/libavformat/vplayerdec.c +++ b/libavformat/vplayerdec.c @@ -101,7 +101,7 @@ const FFInputFormat ff_vplayer_demuxer = { .p.long_name = NULL_IF_CONFIG_SMALL("VPlayer subtitles"), .p.extensions = "txt", .priv_data_size = sizeof(VPlayerContext), - .flags_internal = FF_FMT_INIT_CLEANUP, + .flags_internal = FF_INFMT_FLAG_INIT_CLEANUP, .read_probe = vplayer_probe, .read_header = vplayer_read_header, .read_packet = ff_subtitles_read_packet, diff --git a/libavformat/wc3movie.c b/libavformat/wc3movie.c index 022b276fbd..c6b182dcbc 100644 --- a/libavformat/wc3movie.c +++ b/libavformat/wc3movie.c @@ -298,7 +298,7 @@ const FFInputFormat ff_wc3_demuxer = { .p.name = "wc3movie", .p.long_name = NULL_IF_CONFIG_SMALL("Wing Commander III movie"), .priv_data_size = sizeof(Wc3DemuxContext), - .flags_internal = FF_FMT_INIT_CLEANUP, + .flags_internal = FF_INFMT_FLAG_INIT_CLEANUP, .read_probe = wc3_probe, .read_header = wc3_read_header, .read_packet = wc3_read_packet, diff --git a/libavformat/webvttdec.c b/libavformat/webvttdec.c index 56fc0f5167..6e60348764 100644 --- a/libavformat/webvttdec.c +++ b/libavformat/webvttdec.c @@ -219,7 +219,7 @@ const FFInputFormat ff_webvtt_demuxer = { .p.extensions = "vtt", .p.priv_class = &webvtt_demuxer_class, .priv_data_size = sizeof(WebVTTContext), - .flags_internal = FF_FMT_INIT_CLEANUP, + .flags_internal = FF_INFMT_FLAG_INIT_CLEANUP, .read_probe = webvtt_probe, .read_header = webvtt_read_header, .read_packet = webvtt_read_packet, diff --git a/libavformat/xmv.c b/libavformat/xmv.c index e2c4c7f93e..6a44d82016 100644 --- a/libavformat/xmv.c +++ b/libavformat/xmv.c @@ -581,7 +581,7 @@ const FFInputFormat ff_xmv_demuxer = { .p.long_name = NULL_IF_CONFIG_SMALL("Microsoft XMV"), .p.extensions = "xmv", .priv_data_size = sizeof(XMVDemuxContext), - .flags_internal = FF_FMT_INIT_CLEANUP, + .flags_internal = FF_INFMT_FLAG_INIT_CLEANUP, .read_probe = xmv_probe, .read_header = xmv_read_header, .read_packet = xmv_read_packet,