From 39821495c82b104b77e628d5cb244be041e285ed Mon Sep 17 00:00:00 2001 From: handbrake Date: Tue, 22 Jan 2013 08:58:10 +0000 Subject: [PATCH] modified the opencl init error. it can work well with mingw64 compiled. git-svn-id: svn://svn.handbrake.fr/HandBrake/branches/opencl@5190 b64f7644-9d1e-0410-96f1-a4d463321fa5 --- libhb/openclwrapper.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/libhb/openclwrapper.c b/libhb/openclwrapper.c index 3a0f12f3e..a10e9d64d 100644 --- a/libhb/openclwrapper.c +++ b/libhb/openclwrapper.c @@ -656,6 +656,8 @@ int hb_compile_kernel_file( const char *filename, GPUEnv *gpu_info, #ifdef USE_EXTERNAL_KERNEL status = hb_convert_to_string( filename, &source_str, gpu_info, idx ); + if( status == 0 ) + return(0); #else int kernel_src_size = strlen( kernel_src_hscale )+strlen( kernel_src_vscale )+strlen( kernel_src_nvtoyuv ); source_str = (char*)malloc( kernel_src_size+2 ); @@ -664,8 +666,6 @@ int hb_compile_kernel_file( const char *filename, GPUEnv *gpu_info, strcat( source_str, kernel_src_nvtoyuv ); #endif - if( status == 0 ) - return(0); source = source_str; source_size[0] = strlen( source ); -- 2.40.0