avutil/opencl: fix a segmentfault in libavutil/opencl.c

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
pull/108/head
Y.C. Liu 11 years ago committed by Michael Niedermayer
parent 6e5cce1cbe
commit cebe06a0bf
  1. 2
      libavutil/opencl.c

@ -169,7 +169,7 @@ static const OpenclErrorMsg opencl_err_msg[] = {
const char *av_opencl_errstr(cl_int status) const char *av_opencl_errstr(cl_int status)
{ {
int i; int i;
for (i = 0; i < sizeof(opencl_err_msg); i++) { for (i = 0; i < FF_ARRAY_ELEMS(opencl_err_msg); i++) {
if (opencl_err_msg[i].err_code == status) if (opencl_err_msg[i].err_code == status)
return opencl_err_msg[i].err_str; return opencl_err_msg[i].err_str;
} }

Loading…
Cancel
Save