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 C10E243A85 for ; Wed, 6 Jul 2022 19:50:30 +0000 (UTC) Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id 2936D68BAB9; Wed, 6 Jul 2022 22:50:27 +0300 (EEST) Received: from btbn.de (btbn.de [136.243.74.85]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id 91CE468BAA1 for ; Wed, 6 Jul 2022 22:50:20 +0300 (EEST) Received: from [authenticated] by btbn.de (Postfix) with ESMTPSA id AF58D34BDB7; Wed, 6 Jul 2022 21:50:19 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=rothenpieler.org; s=mail; t=1657137019; bh=gcHFgghrJABVFrLkM8LdT5JZNUA+wwQnXwdD46jDp44=; h=From:To:Cc:Subject:Date; b=W6LP4Idtlfbr5GmeIn5PpzU7yuj5baUEc4ym48nTtCrsZzFVXr6Jgyknu4XpiGbqT MRhoiu8NrwmJAxFxY8IT7Asc1mi9w0w5COHGkVmtfI0m2isTzBx1BzEL3vnLMAglcr H727bulGf4YLfmFTAtJdLiAOGYpcpw/Tp6o6/dQ4PcyF3vjl54TKEKXZmv+4A3lqak HTuQ+0kOVQFOfXkU9MclnGy4maDbK4pL526e1krjPnoCiBXAWWTn0AmpwXbQCjYQ1D CWHPMSv2pnXn7RujNNmj402K0JqfD+CeGuTygCHrwkVznXPrPuYMgA5bs2+gq4JZB8 gjrQrHuX7x0PA== From: Timo Rothenpieler To: ffmpeg-devel@ffmpeg.org Date: Wed, 6 Jul 2022 21:50:02 +0200 Message-Id: <20220706195003.16703-1-timo@rothenpieler.org> X-Mailer: git-send-email 2.34.1 MIME-Version: 1.0 Subject: [FFmpeg-devel] [PATCH 1/2] avutil/hwcontext_d3d11va: fix mixed declaration and code 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: Timo Rothenpieler 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: --- libavutil/hwcontext_d3d11va.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/libavutil/hwcontext_d3d11va.c b/libavutil/hwcontext_d3d11va.c index 904d14bbc8..e5afcb2a9d 100644 --- a/libavutil/hwcontext_d3d11va.c +++ b/libavutil/hwcontext_d3d11va.c @@ -397,6 +397,7 @@ static int d3d11va_transfer_data(AVHWFramesContext *ctx, AVFrame *dst, D3D11_TEXTURE2D_DESC desc; D3D11_MAPPED_SUBRESOURCE map; HRESULT hr; + int res; if (frame->hw_frames_ctx->data != (uint8_t *)ctx || other->format != ctx->sw_format) return AVERROR(EINVAL); @@ -405,7 +406,7 @@ static int d3d11va_transfer_data(AVHWFramesContext *ctx, AVFrame *dst, if (!s->staging_texture) { ID3D11Texture2D_GetDesc((ID3D11Texture2D *)texture, &desc); - int res = d3d11va_create_staging_texture(ctx, desc.Format); + res = d3d11va_create_staging_texture(ctx, desc.Format); if (res < 0) return res; } -- 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".