svga: add some sanity check assertions in svga_buffer_transfer_map()

Make sure y and z values of buffers are as expected.

Reviewed-by: José Fonseca <jfonseca@vmware.com>
Reviewed-by: Charmaine Lee <charmainel@vmware.com>
This commit is contained in:
Brian Paul
2015-11-19 10:39:09 -07:00
parent b109cd3c27
commit e96d7a1489
@@ -80,6 +80,11 @@ svga_buffer_transfer_map(struct pipe_context *pipe,
uint8_t *map;
int64_t begin = os_time_get();
assert(box->y == 0);
assert(box->z == 0);
assert(box->height == 1);
assert(box->depth == 1);
transfer = CALLOC_STRUCT(pipe_transfer);
if (transfer == NULL) {
return NULL;