From 53ef055f5eb17133e694cfe3be1271f04ac4703e Mon Sep 17 00:00:00 2001 From: jojo61 Date: Thu, 11 Oct 2018 22:12:22 +0200 Subject: [PATCH] more fixes --- video.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/video.c b/video.c index 875b03b..93a4385 100644 --- a/video.c +++ b/video.c @@ -1765,6 +1765,7 @@ static void CuvidDestroySurfaces(CuvidDecoder * decoder) GlxCheck(); if (decoder->cuda_ctx) { + checkCudaErrors(cuCtxPushCurrent(decoder->cuda_ctx)); for (i=0;iSurfacesNeeded;i++) { for (j=0;j<2;j++) { if (decoder->cu_res[i][j]) { @@ -1773,6 +1774,7 @@ static void CuvidDestroySurfaces(CuvidDecoder * decoder) } } } + checkCudaErrors(cuCtxPopCurrent(NULL)); }