We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 51f1149 commit dd5631aCopy full SHA for dd5631a
1 file changed
include/CL/opencl.hpp
@@ -3648,8 +3648,8 @@ class Context
3648
cl_mem_object_type type,
3649
vector<ImageFormat>* formats) const
3650
{
3651
- if (!formats) {
3652
- return CL_SUCCESS;
+ if( formats == nullptr ) {
+ return detail::errHandler(CL_INVALID_ARG_VALUE, __GET_SUPPORTED_IMAGE_FORMATS_ERR);
3653
}
3654
return getSupportedImageFormats(flags, type, *formats);
3655
0 commit comments