From 5409734129af9076ac81a4bfc980a4a05a4323f5 Mon Sep 17 00:00:00 2001 From: Samuel Iglesias Gonsalvez Date: Tue, 1 Apr 2014 11:19:09 +0200 Subject: [PATCH] mesa: fix check for dummy renderbuffer in _mesa_FramebufferRenderbufferEXT() According to the spec: must be RENDERBUFFER and should be set to the name of the renderbuffer object to be attached to the framebuffer. must be either zero or the name of an existing renderbuffer object of type , otherwise an INVALID_OPERATION error is generated. This patch changes the previous returned GL_INVALID_VALUE to GL_INVALID_OPERATION. Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=76894 Signed-off-by: Samuel Iglesias Gonsalvez --- src/mesa/main/fbobject.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/mesa/main/fbobject.c b/src/mesa/main/fbobject.c index 6c4f1b5..7669a0c 100644 --- a/src/mesa/main/fbobject.c +++ b/src/mesa/main/fbobject.c @@ -2676,8 +2676,7 @@ _mesa_FramebufferRenderbuffer(GLenum target, GLenum attachment, return; } else if (rb == &DummyRenderbuffer) { - /* This is what NVIDIA does */ - _mesa_error(ctx, GL_INVALID_VALUE, + _mesa_error(ctx, GL_INVALID_OPERATION, "glFramebufferRenderbufferEXT(renderbuffer %u)", renderbuffer); return; -- 1.9.1