[FFmpeg-cvslog] libavdevice/dshow.c: Correct CoGetMalloc check

FearThe1337 git at videolan.org
Sun Feb 14 00:12:06 CET 2016


ffmpeg | branch: master | FearThe1337 <git at fearthe1337.com> | Sat Feb 13 16:55:02 2016 +0100| [c33ffc7b21b9531a971b5da1edcae0b308fe88aa] | committer: Michael Niedermayer

libavdevice/dshow.c: Correct CoGetMalloc check

Current if statement would always be false due to assigning the value of
S_OK which equals 0.

Signed-off-by: FearThe1337 <git at fearthe1337.com>
Signed-off-by: Michael Niedermayer <michael at niedermayer.cc>

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

 libavdevice/dshow.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/libavdevice/dshow.c b/libavdevice/dshow.c
index b280bc3..f56c165 100644
--- a/libavdevice/dshow.c
+++ b/libavdevice/dshow.c
@@ -240,7 +240,7 @@ dshow_cycle_devices(AVFormatContext *avctx, ICreateDevEnum *devenum,
         int i;
 
         r = CoGetMalloc(1, &co_malloc);
-        if (r = S_OK)
+        if (r != S_OK)
             goto fail1;
         r = CreateBindCtx(0, &bind_ctx);
         if (r != S_OK)



More information about the ffmpeg-cvslog mailing list