Mesa (10.4): mesa: Correct backwards NULL check.
Emil Velikov
evelikov at kemper.freedesktop.org
Fri Mar 6 19:42:33 UTC 2015
Module: Mesa
Branch: 10.4
Commit: 644bbf88ec8fe876efda7aa6615f8a89d0101bd0
URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=644bbf88ec8fe876efda7aa6615f8a89d0101bd0
Author: Matt Turner <mattst88 at gmail.com>
Date: Sat Feb 28 11:14:02 2015 -0800
mesa: Correct backwards NULL check.
Cc: "10.4, 10.5" <mesa-stable at lists.freedesktop.org>
Reviewed-by: Emil Velikov <emil.l.velikov at gmail.com>
Reviewed-by: Ian Romanick <ian.d.romanick at intel.com>
(cherry picked from commit 491d42135ad0e5670756216154f2ba9fc79d4ba7)
---
src/mesa/main/shaderapi.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/mesa/main/shaderapi.c b/src/mesa/main/shaderapi.c
index 0ca4f58..3e2f883 100644
--- a/src/mesa/main/shaderapi.c
+++ b/src/mesa/main/shaderapi.c
@@ -1696,7 +1696,7 @@ _mesa_GetProgramBinary(GLuint program, GLsizei bufSize, GLsizei *length,
* Ensure that length always points to valid storage to avoid multiple NULL
* pointer checks below.
*/
- if (length != NULL)
+ if (length == NULL)
length = &length_dummy;
More information about the mesa-commit
mailing list