summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/mesa/main/context.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/mesa/main/context.c b/src/mesa/main/context.c
index 7ecd241e6eb..76763489b9f 100644
--- a/src/mesa/main/context.c
+++ b/src/mesa/main/context.c
@@ -1550,7 +1550,7 @@ _mesa_check_init_viewport(struct gl_context *ctx, GLuint width, GLuint height)
static void
handle_first_current(struct gl_context *ctx)
{
- if (ctx->Version == 0) {
+ if (ctx->Version == 0 || !ctx->DrawBuffer) {
/* probably in the process of tearing down the context */
return;
}