diff options
author | Gert Wollny <[email protected]> | 2017-11-16 16:10:01 +0100 |
---|---|---|
committer | Brian Paul <[email protected]> | 2017-11-17 09:27:58 -0700 |
commit | b50eda849805c51f83d57402e7d5e90fad7fe085 (patch) | |
tree | d6a686691ac73c7516b25a75ed09abdc1ac99ceb /src | |
parent | c7bf83ef5cf65d2ed730fcb2e560cd6531a5953a (diff) |
gallium/aux/util/u_surface.c: Silence warnings and remove unneeded MAYBE_UNUSED
* Explicitely convert values to int in comparison.
* Remove one MAYBE_UNUSED that is actually not needed.
Signed-off-by: Gert Wollny <[email protected]>
Reviewed-by: Brian Paul <[email protected]>
Diffstat (limited to 'src')
-rw-r--r-- | src/gallium/auxiliary/util/u_surface.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/gallium/auxiliary/util/u_surface.c b/src/gallium/auxiliary/util/u_surface.c index c66f279dc2e..5f07eb1cdac 100644 --- a/src/gallium/auxiliary/util/u_surface.c +++ b/src/gallium/auxiliary/util/u_surface.c @@ -259,7 +259,7 @@ util_resource_copy_region(struct pipe_context *pipe, struct pipe_transfer *src_trans, *dst_trans; uint8_t *dst_map; const uint8_t *src_map; - MAYBE_UNUSED enum pipe_format src_format; + enum pipe_format src_format; enum pipe_format dst_format; struct pipe_box src_box, dst_box; unsigned src_bs, dst_bs, src_bw, dst_bw, src_bh, dst_bh; @@ -328,10 +328,10 @@ util_resource_copy_region(struct pipe_context *pipe, assert(dst_box.y % dst_bh == 0); /* check that region boxes are not out of bounds */ - assert(src_box.x + src_box.width <= u_minify(src->width0, src_level)); - assert(src_box.y + src_box.height <= u_minify(src->height0, src_level)); - assert(dst_box.x + dst_box.width <= u_minify(dst->width0, dst_level)); - assert(dst_box.y + dst_box.height <= u_minify(dst->height0, dst_level)); + assert(src_box.x + src_box.width <= (int)u_minify(src->width0, src_level)); + assert(src_box.y + src_box.height <= (int)u_minify(src->height0, src_level)); + assert(dst_box.x + dst_box.width <= (int)u_minify(dst->width0, dst_level)); + assert(dst_box.y + dst_box.height <= (int)u_minify(dst->height0, dst_level)); /* check that total number of src, dest bytes match */ assert((src_box.width / src_bw) * (src_box.height / src_bh) * src_bs == |