From: Jordan Justen Date: Mon, 16 Jul 2012 22:41:26 +0000 (-0700) Subject: mesa context: generate an error for uninstalled context functions X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=01168df4d999f84105928d69fdd3eeed6baeeab4;p=mesa.git mesa context: generate an error for uninstalled context functions For 'non-legacy' contexts we will want to generate an error if an uninstalled function is called. The effect of this change will be that we can avoid installing legacy functions, and they will then generate an error as needed for deprecated functions in GL >= 3.1. Signed-off-by: Jordan Justen Reviewed-by: Kenneth Graunke Reviewed-by: Ian Romanick --- diff --git a/src/mesa/main/context.c b/src/mesa/main/context.c index 1546c886f8b..41550f990a4 100644 --- a/src/mesa/main/context.c +++ b/src/mesa/main/context.c @@ -842,7 +842,10 @@ update_default_objects(struct gl_context *ctx) static int generic_nop(void) { - _mesa_warning(NULL, "User called no-op dispatch function (an unsupported extension function?)"); + GET_CURRENT_CONTEXT(ctx); + _mesa_error(ctx, GL_INVALID_OPERATION, + "unsupported function called " + "(unsupported extension or deprecated function?)"); return 0; }