From patchwork Sun Feb 17 19:44:52 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Marton Balint X-Patchwork-Id: 12088 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 841FB448F95 for ; Sun, 17 Feb 2019 21:46:10 +0200 (EET) Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id 729E868A9FA; Sun, 17 Feb 2019 21:46:10 +0200 (EET) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from iq.passwd.hu (iq.passwd.hu [217.27.212.140]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id 90A5068A32E for ; Sun, 17 Feb 2019 21:46:02 +0200 (EET) Received: from localhost (localhost [127.0.0.1]) by iq.passwd.hu (Postfix) with ESMTP id 7BADEE13FC; Sun, 17 Feb 2019 20:46:02 +0100 (CET) X-Virus-Scanned: amavisd-new at passwd.hu Received: from iq.passwd.hu ([127.0.0.1]) by localhost (iq.passwd.hu [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id eyqi-1LWzY4Y; Sun, 17 Feb 2019 20:46:01 +0100 (CET) Received: from bluegene.passwd.hu (localhost [127.0.0.1]) by iq.passwd.hu (Postfix) with ESMTP id 66DF3E141B; Sun, 17 Feb 2019 20:46:01 +0100 (CET) From: Marton Balint To: ffmpeg-devel@ffmpeg.org Date: Sun, 17 Feb 2019 20:44:52 +0100 Message-Id: <20190217194453.8030-2-cus@passwd.hu> X-Mailer: git-send-email 2.16.4 In-Reply-To: <20190217194453.8030-1-cus@passwd.hu> References: <20190217194453.8030-1-cus@passwd.hu> Subject: [FFmpeg-devel] [PATCH 2/3] avcodec/get_bits: use unsigned integers in show_bits and get_bits 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: Marton Balint MIME-Version: 1.0 Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" The return value is also unsigned. --- libavcodec/get_bits.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/libavcodec/get_bits.h b/libavcodec/get_bits.h index 26a5b3e54f..2e2adc29c2 100644 --- a/libavcodec/get_bits.h +++ b/libavcodec/get_bits.h @@ -380,7 +380,7 @@ static inline int get_sbits(GetBitContext *s, int n) */ static inline unsigned int get_bits(GetBitContext *s, int n) { - register int tmp; + register unsigned int tmp; #if CACHED_BITSTREAM_READER av_assert2(n>0 && n<=32); @@ -442,7 +442,7 @@ static inline unsigned int get_bits_le(GetBitContext *s, int n) */ static inline unsigned int show_bits(GetBitContext *s, int n) { - register int tmp; + register unsigned int tmp; #if CACHED_BITSTREAM_READER if (n > s->bits_left) refill_32(s);