Mesa (master): i965: Return the correct value type from brw_compile_gs()
Eduardo Lima Mitev
elima at kemper.freedesktop.org
Tue Nov 17 11:52:22 UTC 2015
Module: Mesa
Branch: master
Commit: 252b143e9e8ca0b98143c237f14cb0b548ffd510
URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=252b143e9e8ca0b98143c237f14cb0b548ffd510
Author: Eduardo Lima Mitev <elima at igalia.com>
Date: Tue Nov 17 09:49:43 2015 +0100
i965: Return the correct value type from brw_compile_gs()
brw_compile_gs() should return a pointer to unsigned, but it is returning the
bool 'false' at some point, hence annoying us with a compiler warning:
In function 'const unsigned int* brw::brw_compile_gs(const brw_compiler*,
void*, void*, const brw_gs_prog_key*, brw_gs_prog_data*, const nir_shader*,
gl_shader_program*, int, unsigned int*, char**)':
brw_vec4_gs_visitor.cpp:776:14: warning: converting 'false' to pointer type
'const unsigned int*' [-Wconversion-null]
return false;
^
Reviewed-by: Jordan Justen <jordan.l.justen at intel.com>
---
src/mesa/drivers/dri/i965/brw_vec4_gs_visitor.cpp | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/mesa/drivers/dri/i965/brw_vec4_gs_visitor.cpp b/src/mesa/drivers/dri/i965/brw_vec4_gs_visitor.cpp
index 81353ae..0c49865 100644
--- a/src/mesa/drivers/dri/i965/brw_vec4_gs_visitor.cpp
+++ b/src/mesa/drivers/dri/i965/brw_vec4_gs_visitor.cpp
@@ -773,7 +773,7 @@ brw_compile_gs(const struct brw_compiler *compiler, void *log_data,
if (compiler->devinfo->gen == 6)
max_output_size_bytes = GEN6_MAX_GS_URB_ENTRY_SIZE_BYTES;
if (output_size_bytes > max_output_size_bytes)
- return false;
+ return NULL;
/* URB entry sizes are stored as a multiple of 64 bytes in gen7+ and
More information about the mesa-commit
mailing list