virgl/transfer: take transfer offset into a/c

This checks the offset can fit inside the iovec
macos/master
Dave Airlie 10 years ago
parent 88b48d0606
commit bc975ef808
  1. 4
      src/vrend_renderer.c

@ -3701,7 +3701,11 @@ static bool check_iov_bounds(struct vrend_resource *res,
GLuint iovsize = vrend_get_iovec_size(iov, num_iovs);
if (iovsize < info->offset)
return false;
if (iovsize < send_size)
return false;
if (iovsize < info->offset + send_size)
return false;
return true;
}

Loading…
Cancel
Save