[Mesa-dev] [PATCH] [rfc] mesa/debug_output: fix returned message length.

Dave Airlie airlied at gmail.com
Tue May 3 20:52:44 UTC 2016


From: Dave Airlie <airlied at redhat.com>

This fixes both:
GL43-CTS.khr_debug.receiveing_messages
GL43-CTS.khr_debug.groups

which reported off by ones.

Signed-off-by: Dave Airlie <airlied at redhat.com>
---
 src/mesa/main/debug_output.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/mesa/main/debug_output.c b/src/mesa/main/debug_output.c
index 85f64bd..3d46391 100644
--- a/src/mesa/main/debug_output.c
+++ b/src/mesa/main/debug_output.c
@@ -1076,7 +1076,7 @@ _mesa_GetDebugMessageLog(GLuint count, GLsizei logSize, GLenum *sources,
       }
 
       if (lengths)
-         *lengths++ = len+1;
+         *lengths++ = len;
       if (severities)
          *severities++ = debug_severity_enums[msg->severity];
       if (sources)
-- 
2.5.5



More information about the mesa-dev mailing list