Mesa (7.11): mesa: fix error handling for glEvalMesh1/2D

Ian Romanick idr at kemper.freedesktop.org
Mon Oct 24 15:54:48 PDT 2011


Module: Mesa
Branch: 7.11
Commit: 23a3753a287521ab35eb9ee93f8bc00311465a8b
URL:    http://cgit.freedesktop.org/mesa/mesa/commit/?id=23a3753a287521ab35eb9ee93f8bc00311465a8b

Author: Yuanhan Liu <yuanhan.liu at linux.intel.com>
Date:   Mon Sep 19 15:02:58 2011 +0800

mesa: fix error handling for glEvalMesh1/2D

According man page, trigger error when calling glEvalMesh1/2D inside
glBegin/glEnd.

Signed-off-by: Yuanhan Liu <yuanhan.liu at linux.intel.com>
Signed-off-by: Brian Paul <brianp at vmware.com>
(cherry picked from commit 21b2895bd0df1b7b6f6defeff1dc2084152f51e5)

---

 src/mesa/main/api_noop.c |    4 ++++
 1 files changed, 4 insertions(+), 0 deletions(-)

diff --git a/src/mesa/main/api_noop.c b/src/mesa/main/api_noop.c
index 7d3d332..c4ac95c 100644
--- a/src/mesa/main/api_noop.c
+++ b/src/mesa/main/api_noop.c
@@ -892,6 +892,8 @@ _mesa_noop_EvalMesh1( GLenum mode, GLint i1, GLint i2 )
    GLfloat u, du;
    GLenum prim;
 
+   ASSERT_OUTSIDE_BEGIN_END(ctx);
+
    switch (mode) {
    case GL_POINT:
       prim = GL_POINTS;
@@ -930,6 +932,8 @@ _mesa_noop_EvalMesh2( GLenum mode, GLint i1, GLint i2, GLint j1, GLint j2 )
    GLfloat u, du, v, dv, v1, u1;
    GLint i, j;
 
+   ASSERT_OUTSIDE_BEGIN_END(ctx);
+
    switch (mode) {
    case GL_POINT:
    case GL_LINE:



More information about the mesa-commit mailing list