From patchwork Tue Aug 6 11:50:40 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Gaullier Nicolas X-Patchwork-Id: 14263 Return-Path: X-Original-To: patchwork@ffaux-bg.ffmpeg.org Delivered-To: patchwork@ffaux-bg.ffmpeg.org Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org [79.124.17.100]) by ffaux.localdomain (Postfix) with ESMTP id BEDC344A215 for ; Tue, 6 Aug 2019 14:50:58 +0300 (EEST) Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id AEA2768A9A0; Tue, 6 Aug 2019 14:50:58 +0300 (EEST) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from smtp-2.arkena.net (smtp-2.arkena.net [95.81.173.75]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id 766F8680409 for ; Tue, 6 Aug 2019 14:50:51 +0300 (EEST) Received: from secu2 (unknown [10.180.103.10]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by smtp-2.arkena.net (Postfix) with ESMTPSA id 462tHt3bdNzHh97; Tue, 6 Aug 2019 11:50:50 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=arkena.com; s=20150421; t=1565092250; bh=o+1+IgqBis1jLU+xLk18YST8uL2eqtP7VORAZQw0Cws=; h=From:To:Cc:Subject:Date:Message-Id; b=JIdBG83AFU+bURwlmNwu9Sc8PralVw57/ilxQ2piPlHY9A/AB0mxlG8y5W83uOCxr OMTlirqsTWHD5WLs4OBvuwxujeFyTUGCc3eO5P39pIQHIvpQUd1Ilfe07tg5p8FwsZ rZrBT/BQvSgeecfwG8puHc/gawAenbhlkTgMBo30= Received: from arkena.com (unknown [172.16.3.159]) by secu2 (Postfix) with ESMTP id 13F683FA71; Tue, 6 Aug 2019 13:28:02 +0200 (CEST) From: Nicolas Gaullier To: ffmpeg-devel@ffmpeg.org Date: Tue, 6 Aug 2019 13:50:40 +0200 Message-Id: <20190806115044.4116-2-nicolas.gaullier@arkena.com> X-Mailer: git-send-email 2.14.1.windows.1 In-Reply-To: <20190806115044.4116-1-nicolas.gaullier@arkena.com> References: <20190806115044.4116-1-nicolas.gaullier@arkena.com> Subject: [FFmpeg-devel] [PATCH v2 1/5] avformat/s337m: Use base AVClass for av_log usage X-BeenThere: ffmpeg-devel@ffmpeg.org X-Mailman-Version: 2.1.20 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: Nicolas Gaullier MIME-Version: 1.0 Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" s337m_get_offset_and_codec does not make use of AVFormatContext: AVClass is enough for logging. Will facilitate further use from outside --- libavformat/s337m.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/libavformat/s337m.c b/libavformat/s337m.c index 48ab66a6da..8956afb23f 100644 --- a/libavformat/s337m.c +++ b/libavformat/s337m.c @@ -31,7 +31,7 @@ #define IS_24LE_MARKER(state) ((state & 0xFFFFFFFFFFFF) == MARKER_24LE) #define IS_LE_MARKER(state) (IS_16LE_MARKER(state) || IS_20LE_MARKER(state) || IS_24LE_MARKER(state)) -static int s337m_get_offset_and_codec(AVFormatContext *s, +static int s337m_get_offset_and_codec(void *avc, uint64_t state, int data_type, int data_size, int *offset, enum AVCodecID *codec) @@ -50,8 +50,8 @@ static int s337m_get_offset_and_codec(AVFormatContext *s, } if ((data_type & 0x1F) != 0x1C) { - if (s) - avpriv_report_missing_feature(s, "Data type %#x in SMPTE 337M", data_type & 0x1F); + if (avc) + avpriv_report_missing_feature(avc, "Data type %#x in SMPTE 337M", data_type & 0x1F); return AVERROR_PATCHWELCOME; } @@ -72,8 +72,8 @@ static int s337m_get_offset_and_codec(AVFormatContext *s, *offset = 1601; break; default: - if (s) - avpriv_report_missing_feature(s, "Dolby E data size %d in SMPTE 337M", data_size); + if (avc) + avpriv_report_missing_feature(avc, "Dolby E data size %d in SMPTE 337M", data_size); return AVERROR_PATCHWELCOME; }