Mesa (master): mesa: fixup cast expression

GitLab Mirror gitlab-mirror at kemper.freedesktop.org
Thu Apr 16 15:09:18 UTC 2020


Module: Mesa
Branch: master
Commit: b55b033f7624171d82ae1f79f3d3ad058ae0ac56
URL:    http://cgit.freedesktop.org/mesa/mesa/commit/?id=b55b033f7624171d82ae1f79f3d3ad058ae0ac56

Author: Erik Faye-Lund <erik.faye-lund at collabora.com>
Date:   Wed Apr 15 22:26:59 2020 +0200

mesa: fixup cast expression

This cast-expression was meant to cast the result of the terniary
expression, but it just casted the condition expression instead. Let's
correct this, to silence a compiler-warning.

Reviewed-by: Brian Paul <brianp at vmware.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4577>

---

 src/mesa/main/varray.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/mesa/main/varray.c b/src/mesa/main/varray.c
index 140c84de2b1..0dd630c7a3a 100644
--- a/src/mesa/main/varray.c
+++ b/src/mesa/main/varray.c
@@ -3793,7 +3793,7 @@ _mesa_print_arrays(struct gl_context *ctx)
               array->Ptr, _mesa_enum_to_string(array->Format.Type),
               array->Format.Size,
               array->Format._ElementSize, binding->Stride, bo ? bo->Name : 0,
-              (unsigned long) bo ? bo->Size : 0);
+              (unsigned long)(bo ? bo->Size : 0));
    }
 }
 



More information about the mesa-commit mailing list