Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBrecht Van Lommel <brechtvanlommel@pandora.be>2012-02-28 20:44:36 +0400
committerBrecht Van Lommel <brechtvanlommel@pandora.be>2012-02-28 20:44:36 +0400
commitaecff24add56e6724744928efe5ad7f1947416b7 (patch)
tree1ac2899409c341d976f3f54b89ecf15abf40d973 /intern/cycles/util
parentc48a5fd821d0270cdd974315f8d49987b53a1795 (diff)
Cycles: extra OpenCL NULL point check, maybe avoids some crashes. Don't think
this should ever happen in practice but maybe it does anyway.
Diffstat (limited to 'intern/cycles/util')
-rw-r--r--intern/cycles/util/util_opencl.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/intern/cycles/util/util_opencl.cpp b/intern/cycles/util/util_opencl.cpp
index 1d05b0b687a..4087c2c3823 100644
--- a/intern/cycles/util/util_opencl.cpp
+++ b/intern/cycles/util/util_opencl.cpp
@@ -235,6 +235,9 @@ int clLibraryInit()
__clewEnqueueBarrier = (PFNCLENQUEUEBARRIER )CLCC_DYNLIB_IMPORT(module, "clEnqueueBarrier");
__clewGetExtensionFunctionAddress = (PFNCLGETEXTENSIONFUNCTIONADDRESS )CLCC_DYNLIB_IMPORT(module, "clGetExtensionFunctionAddress");
+ if(__clewGetPlatformIDs == NULL)
+ return 0;
+
return 1;
}