[FFmpeg-cvslog] hwcontext_opencl: Reset internal command queue on device_uninit

Mark Thompson git at videolan.org
Sat Nov 25 18:08:42 EET 2017


ffmpeg | branch: master | Mark Thompson <sw at jkqxz.net> | Sat Nov 25 15:34:43 2017 +0000| [f4e319d8a94697f21802e2682085599a93a39a57] | committer: Mark Thompson

hwcontext_opencl: Reset internal command queue on device_uninit

device_uninit can be called twice if device_init fails.

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

 libavutil/hwcontext_opencl.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/libavutil/hwcontext_opencl.c b/libavutil/hwcontext_opencl.c
index 8754d73939..b00c1b6409 100644
--- a/libavutil/hwcontext_opencl.c
+++ b/libavutil/hwcontext_opencl.c
@@ -883,6 +883,7 @@ static void opencl_device_uninit(AVHWDeviceContext *hwdev)
             av_log(hwdev, AV_LOG_ERROR, "Failed to release internal "
                    "command queue reference: %d.\n", cle);
         }
+        priv->command_queue = NULL;
     }
 }
 



More information about the ffmpeg-cvslog mailing list