From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org [79.124.17.100]) by master.gitmailbox.com (Postfix) with ESMTP id B82C24B95D for ; Tue, 2 Jul 2024 06:03:42 +0000 (UTC) Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id 5F16868D8AE; Tue, 2 Jul 2024 09:03:39 +0300 (EEST) Received: from mail-io1-f98.google.com (mail-io1-f98.google.com [209.85.166.98]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id 8EEE468D6D2 for ; Tue, 2 Jul 2024 09:03:33 +0300 (EEST) Received: by mail-io1-f98.google.com with SMTP id ca18e2360f4ac-7f3d59ff826so137798239f.3 for ; Mon, 01 Jul 2024 23:03:33 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=proxyid.net; s=google; t=1719900212; x=1720505012; darn=ffmpeg.org; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:from:to:cc:subject:date:message-id:reply-to; bh=8BEYrMqIdJDvq8XUjyuhFB+/SFq32Fv4/gENrBlNw2U=; b=ahiydH/GZJ0CHcRV+j5zZ1lFYMdftWu0hv9bxKHKV8lqBl3mticp+zqeB45H6VB4j1 at8WAbK4MJSBxxdCqHCHo1FfFiRfhLl+2WOnmyFbyg32Aw/GIPDJigWTxni8ScSqjk0o 3T+WrxpAS7cx9vKamgRsdBZT4pYq8Szr+BBZGm6vcAcRZcr4sOIuVvE2oXVRJBiW+17r qwQftxitNZp0zArfFMWnXbd4dC11dPooHL34shL4Mnoiws4o4YEZiwo7u5GKa2BoN0Bk fAJKBhfGqAys199czRWXYJj3EXUD8e6fHmO8sQKAQrpN8It6uIRCUOM68xUXHuVBLy82 P3yg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1719900212; x=1720505012; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=8BEYrMqIdJDvq8XUjyuhFB+/SFq32Fv4/gENrBlNw2U=; b=dCo+/WanisQXwDOcyrjwdiycMvbKqu/wv5s8WT2FpCFEESloHh38NlwS1c45/ttxPk SK/d794SAUlcBmg8TKNoV7qqLnkLZ4DhCcbkDoXrM4RoYVoNvxwjQ/1jvXAXqQuwMlVo FKEYazsVLNSyQoz1PtQxTXnGn5hNl3zyayMXYsdXo7PRhHksF8B6XugAN99GOd9alZD5 LVhUCRJuM8eeILHtcOdEOkRulOnTnWEjJzmeSWGuebdC8gyDh6BCA2XRixPCJelUjjn5 7l0M1lM5LFAbEGJsc6+QcUfQ0hQUdcP9sP8phsgJ/M5TYe+4bxMnIL9XSk8h9MWF/goH ufXQ== X-Gm-Message-State: AOJu0Yz6OoaezlXvuYMAavjVF/yM1dEoJQGAHTkcFxTqXvfVvLLpgUCd f3UZFPp8MMXXy28fayA78bTcbhbHQmApsa+9mJ1io02sdm1y2lq2gC0AiHR2qD34kRDzohbpQME /yC/LsD9kOeub1vIK7M89KIwyz2ao6VzQDZIeI/rw X-Google-Smtp-Source: AGHT+IGXkF+NeTbILmrcLQW6bi37cZBHgM5IX5BrRP+siLDLTWr/d5fOqFeSiUMXZV0BOX1JtXo1mg1veWcQ X-Received: by 2002:a6b:d807:0:b0:7f6:1ed4:daab with SMTP id ca18e2360f4ac-7f62eea16ccmr674595139f.16.1719900211857; Mon, 01 Jul 2024 23:03:31 -0700 (PDT) Received: from wsx-cc1-001.. (c-76-136-218-80.hsd1.il.comcast.net. [76.136.218.80]) by smtp-relay.gmail.com with ESMTPS id 8926c6da1cb9f-4bb73e27e98sm197044173.40.2024.07.01.23.03.31 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 01 Jul 2024 23:03:31 -0700 (PDT) X-Relaying-Domain: proxyid.net From: Marth64 To: ffmpeg-devel@ffmpeg.org Date: Tue, 2 Jul 2024 01:03:29 -0500 Message-Id: <20240702060329.1309157-1-marth64@proxyid.net> X-Mailer: git-send-email 2.34.1 MIME-Version: 1.0 Subject: [FFmpeg-devel] [PATCH] avformat/dvdvideodec: Remove redundant ret initializations 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: Marth64 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" Archived-At: List-Archive: List-Post: Remove initializing ret = 0, in areas where ret is only used to hold an error value, immediately returned, and the function would otherwise return a literal 0. Signed-off-by: Marth64 --- libavformat/dvdvideodec.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/libavformat/dvdvideodec.c b/libavformat/dvdvideodec.c index f5b7dd33e5..a825e4c0bd 100644 --- a/libavformat/dvdvideodec.c +++ b/libavformat/dvdvideodec.c @@ -1056,7 +1056,7 @@ static int dvdvideo_video_stream_setup(AVFormatContext *s) { DVDVideoDemuxContext *c = s->priv_data; - int ret = 0; + int ret; DVDVideoVTSVideoStreamEntry entry = {0}; video_attr_t video_attr; @@ -1217,7 +1217,7 @@ static int dvdvideo_audio_stream_add_all(AVFormatContext *s) { DVDVideoDemuxContext *c = s->priv_data; - int ret = 0; + int ret; int nb_streams; if (c->opt_menu) @@ -1324,7 +1324,7 @@ static int dvdvideo_subp_stream_add_internal(AVFormatContext *s, uint32_t offset subp_attr_t subp_attr, enum DVDVideoSubpictureViewport viewport) { - int ret = 0; + int ret; DVDVideoPGCSubtitleStreamEntry entry = {0}; entry.viewport = viewport; @@ -1361,7 +1361,7 @@ static int dvdvideo_subp_stream_add_all(AVFormatContext *s) for (int i = 0; i < nb_streams; i++) { - int ret = 0; + int ret; uint32_t subp_control; subp_attr_t subp_attr; video_attr_t video_attr; @@ -1469,7 +1469,7 @@ static int dvdvideo_subdemux_open(AVFormatContext *s) { DVDVideoDemuxContext *c = s->priv_data; extern const FFInputFormat ff_mpegps_demuxer; - int ret = 0; + int ret; if (!(c->mpeg_buf = av_mallocz(DVDVIDEO_BLOCK_SIZE))) return AVERROR(ENOMEM); @@ -1504,7 +1504,7 @@ static int dvdvideo_read_header(AVFormatContext *s) { DVDVideoDemuxContext *c = s->priv_data; - int ret = 0; + int ret; if (c->opt_menu) { if (c->opt_region || -- 2.34.1 _______________________________________________ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-devel To unsubscribe, visit link above, or email ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".