From c979fe3e200f42ff1fad75ebdbebe69da27e1aaa Mon Sep 17 00:00:00 2001 From: Anuj Phogat Date: Fri, 6 Jan 2012 12:48:45 -0800 Subject: [PATCH] Enable is_front_buffer_rendering variable in case of GL_FRONT_AND_BACK glDrawBuffer(GL_FRONT_AND_BACK) results in to segmentation fault if intel->is_front_buffer_rendering is not enabled with GL_FRONT_AND_BACK. Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=44153 Reported-by: Yi Sun Signed-off-by: Anuj Phogat Reviewed-by: Eric Anholt --- src/mesa/drivers/dri/intel/intel_buffers.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/mesa/drivers/dri/intel/intel_buffers.c b/src/mesa/drivers/dri/intel/intel_buffers.c index 4632751935a..9809f79bbee 100644 --- a/src/mesa/drivers/dri/intel/intel_buffers.c +++ b/src/mesa/drivers/dri/intel/intel_buffers.c @@ -88,7 +88,7 @@ intelDrawBuffer(struct gl_context * ctx, GLenum mode) intel->is_front_buffer_rendering; intel->is_front_buffer_rendering = (mode == GL_FRONT_LEFT) - || (mode == GL_FRONT); + || (mode == GL_FRONT) || (mode == GL_FRONT_AND_BACK); /* If we weren't front-buffer rendering before but we are now, * invalidate our DRI drawable so we'll ask for new buffers -- 2.30.2