check the return values aren't NULL
@ -3307,8 +3307,10 @@ void vrend_renderer_resource_detach_iov(int res_handle,
if (!res) {
return;
}
*iov_p = res->iov;
if (iov_p)
*num_iovs_p = res->num_iovs;
if (num_iovs_p)
res->iov = NULL;
res->num_iovs = 0;