From patchwork Fri Oct 23 10:12:04 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andreas Rheinhardt X-Patchwork-Id: 23170 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 1837044B156 for ; Fri, 23 Oct 2020 13:12:46 +0300 (EEST) Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id ED85968A9D5; Fri, 23 Oct 2020 13:12:45 +0300 (EEST) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from mail-wm1-f65.google.com (mail-wm1-f65.google.com [209.85.128.65]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id EE1CD68A7D8 for ; Fri, 23 Oct 2020 13:12:37 +0300 (EEST) Received: by mail-wm1-f65.google.com with SMTP id e2so907110wme.1 for ; Fri, 23 Oct 2020 03:12:37 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=t5P/8oAKhyTSWnqNGxzFNIgkwI/UdgeqDu4ayjLk4EI=; b=Azo12ogxHcw15xak87GpLPBR61hfENBWRrn80+LjblkiP+7Hr0LY8Zm3ZCIx48OvUJ 2VeAqJ8dBbdvwbLSGsFQqit57W878LogMjyQl07DsPGRahEiY8nPIacxcOTGT6qv3PBB 8y/rjqFa/xYMwuLS/MaCpRGZRoy3MLfoIuLjoLw1aliChsZODzQuwkeLvF+apTLJiXcd b5lTYIjvZFV1Aysrlm0HWbzYnY2rMuoxiBDTcgHSNgePyvNDm1RNTslZtKxUtPqoUiiX eZxI79PpS3RK1idLBeXXgRO2sTFUulau5LdRxGDRK/plKx3kNppeIdHqkiXsZxveMsnv ytpQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=t5P/8oAKhyTSWnqNGxzFNIgkwI/UdgeqDu4ayjLk4EI=; b=j8NeOlsoEHviK2hLz1M2YFy55bPk4uO+paDXmBdL79xl/0RWQs2oxR9h92IgZ/+BRs biBdqqzoonABB+/1MiRVm3VhW7d/xY03sbO5fTF44rL2UhfIcxifYKj9C4/OB8wqb8ik Msxe3+/NS5rFhQIWO8ckgcatecNvzvTmVTzC9uCK13JT9DkO6E2neBjBOhhsV6k8Gb5o RiAOtccC0GMhrhyDHxe9JGz4kZxmQ5UFsKU6ui7yAN1AXPf9m+c33Uug9c6IoTZgi/9M YSEWayYq2jb5u0/dybgcqktGJoI9rVX/eXrOji7LmYHQF5EhWKmU1Bft7DIPSea5qslf pTew== X-Gm-Message-State: AOAM530iBtJTOb0LM2WyPbhPgsQgVTk0t3QgcsJl2Rmxt39h7kd++iUr GR6tbVJsG05zHgznLXYOwTcvdGjKm64= X-Google-Smtp-Source: ABdhPJwHrikRJ4vN3mCOqMwoXEPd+Gc4J5Nup0UChSUVOexpIPqA/xwaKTAULjOMa5b+xt/WnbCn5Q== X-Received: by 2002:a7b:cc89:: with SMTP id p9mr1618268wma.4.1603447957187; Fri, 23 Oct 2020 03:12:37 -0700 (PDT) Received: from sblaptop.fritz.box (ipbcc1aa4b.dynamic.kabel-deutschland.de. [188.193.170.75]) by smtp.gmail.com with ESMTPSA id c130sm2515263wma.1.2020.10.23.03.12.36 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 23 Oct 2020 03:12:36 -0700 (PDT) From: Andreas Rheinhardt To: ffmpeg-devel@ffmpeg.org Date: Fri, 23 Oct 2020 12:12:04 +0200 Message-Id: <20201023101204.760326-3-andreas.rheinhardt@gmail.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20201023101204.760326-1-andreas.rheinhardt@gmail.com> References: <20201023101204.760326-1-andreas.rheinhardt@gmail.com> MIME-Version: 1.0 Subject: [FFmpeg-devel] [PATCH 3/3] avcodec/atrac3: Use least max_depth for get_vlc2() 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: Andreas Rheinhardt Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" Signed-off-by: Andreas Rheinhardt --- libavcodec/atrac3.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/libavcodec/atrac3.c b/libavcodec/atrac3.c index a3e7d96a65..1e884a56b6 100644 --- a/libavcodec/atrac3.c +++ b/libavcodec/atrac3.c @@ -247,7 +247,7 @@ static void read_quant_spectral_coeffs(GetBitContext *gb, int selector, if (selector != 1) { for (i = 0; i < num_codes; i++) { huff_symb = get_vlc2(gb, spectral_coeff_tab[selector-1].table, - ATRAC3_VLC_BITS, 3); + ATRAC3_VLC_BITS, 1); huff_symb += 1; code = huff_symb >> 1; if (huff_symb & 1) @@ -257,7 +257,7 @@ static void read_quant_spectral_coeffs(GetBitContext *gb, int selector, } else { for (i = 0; i < num_codes; i++) { huff_symb = get_vlc2(gb, spectral_coeff_tab[selector - 1].table, - ATRAC3_VLC_BITS, 3); + ATRAC3_VLC_BITS, 1); mantissas[i * 2 ] = mantissa_vlc_tab[huff_symb * 2 ]; mantissas[i * 2 + 1] = mantissa_vlc_tab[huff_symb * 2 + 1]; }