[FFmpeg-cvslog] avcodec/dxva2: initialize hr in ff_dxva2_common_end_frame()

Michael Niedermayer git at videolan.org
Sun Jan 5 01:29:28 EET 2025


ffmpeg | branch: release/2.8 | Michael Niedermayer <michael at niedermayer.cc> | Sun May 26 22:33:11 2024 +0200| [5bc596219341f0a05aa1b163d52176bfec144cc2] | committer: Michael Niedermayer

avcodec/dxva2: initialize hr in ff_dxva2_common_end_frame()

Related: CID1591924 Uninitialized scalar variable
Related: CID1591938 Uninitialized scalar variable

Sponsored-by: Sovereign Tech Fund
Signed-off-by: Michael Niedermayer <michael at niedermayer.cc>
(cherry picked from commit 1d6a2aebae202652feb5964a2d62bdba4e5cc6e4)
Signed-off-by: Michael Niedermayer <michael at niedermayer.cc>

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=5bc596219341f0a05aa1b163d52176bfec144cc2
---

 libavcodec/dxva2.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/libavcodec/dxva2.c b/libavcodec/dxva2.c
index c2f7ac9060..de740c3f2e 100644
--- a/libavcodec/dxva2.c
+++ b/libavcodec/dxva2.c
@@ -140,7 +140,7 @@ int ff_dxva2_common_end_frame(AVCodecContext *avctx, AVFrame *frame,
 #endif
     DECODER_BUFFER_DESC             *buffer = NULL, *buffer_slice = NULL;
     int result, runs = 0;
-    HRESULT hr;
+    HRESULT hr = -1;
     unsigned type;
 
     do {



More information about the ffmpeg-cvslog mailing list