[Mesa-stable] [PATCH 4/4] glsl: Fix no return value for non-void function
Tomasz Figa
tomasz.figa at gmail.com
Sat Sep 27 07:20:02 PDT 2014
Even though scope outside the switch statement is unreachable, the
compiler generates a warning, which is treated as error by Android
toolchain. Fix the issue by adding dummy return statement.
Signed-off-by: Tomasz Figa <tomasz.figa at gmail.com>
CC: <mesa-stable at lists.freedesktop.org>
---
src/glsl/opt_vectorize.cpp | 1 +
1 file changed, 1 insertion(+)
diff --git a/src/glsl/opt_vectorize.cpp b/src/glsl/opt_vectorize.cpp
index 2f71a83583b1..066e15a66447 100644
--- a/src/glsl/opt_vectorize.cpp
+++ b/src/glsl/opt_vectorize.cpp
@@ -229,6 +229,7 @@ write_mask_to_swizzle(unsigned write_mask)
case WRITEMASK_W: return SWIZZLE_W;
}
unreachable("not reached");
+ return 0;
}
/**
--
2.1.1
More information about the mesa-stable
mailing list