summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTimothy Arceri <t_arceri@yahoo.com.au>2013-08-21 00:18:00 -0600
committerIan Romanick <ian.d.romanick@intel.com>2013-08-23 16:41:46 -0700
commit4aa9f013d5141c47ee5e91c226605964244fba90 (patch)
treef9d27c8adb70380e6de286b3e36ed40bb4342015
parent7aefdab219992f804236b93e730037bba6dff6fe (diff)
downloadmesa-4aa9f013d5141c47ee5e91c226605964244fba90.tar.gz
mesa: Fix assertion error with glDebugMessageControl
enums were being converted twice resulting in incorrect values. The extra conversion has been removed and the redundant assert is removed also. Cc: 9.2 <mesa-stable@lists.freedesktop.org> Signed-off-by: Timothy Arceri <t_arceri@yahoo.com.au> Reviewed-by: Brian Paul <brianp@vmware.com> (cherry picked from commit f0072e3c6b0bd46d8ebf7ac0a2cf1bf63dc370e8)
-rw-r--r--src/mesa/main/errors.c15
1 files changed, 2 insertions, 13 deletions
diff --git a/src/mesa/main/errors.c b/src/mesa/main/errors.c
index 5a0758d0b9a..cc93d3bd603 100644
--- a/src/mesa/main/errors.c
+++ b/src/mesa/main/errors.c
@@ -609,11 +609,6 @@ control_app_messages(struct gl_context *ctx, GLenum esource, GLenum etype,
enum mesa_debug_type type = gl_enum_to_debug_type(etype);
enum mesa_debug_severity severity = gl_enum_to_debug_severity(eseverity);
- if (count)
- assert(severity == MESA_DEBUG_SEVERITY_COUNT
- && type != MESA_DEBUG_TYPE_COUNT
- && source != MESA_DEBUG_SOURCE_COUNT);
-
for (i = 0; i < count; i++)
set_message_state(ctx, source, type, ids[i], enabled);
@@ -629,9 +624,6 @@ _mesa_DebugMessageControlARB(GLenum gl_source, GLenum gl_type,
GLsizei count, const GLuint *ids,
GLboolean enabled)
{
- enum mesa_debug_source source;
- enum mesa_debug_type type;
- enum mesa_debug_severity severity;
GET_CURRENT_CONTEXT(ctx);
if (count < 0) {
@@ -651,11 +643,8 @@ _mesa_DebugMessageControlARB(GLenum gl_source, GLenum gl_type,
return;
}
- source = gl_enum_to_debug_source(gl_source);
- type = gl_enum_to_debug_type(gl_type);
- severity = gl_enum_to_debug_severity(gl_severity);
-
- control_app_messages(ctx, source, type, severity, count, ids, enabled);
+ control_app_messages(ctx, gl_source, gl_type, gl_severity,
+ count, ids, enabled);
}
void GLAPIENTRY