From 8f68978caa2ff1a3ebb97b994b8db034a441644f Mon Sep 17 00:00:00 2001 From: =?utf8?q?Marek=20Ol=C5=A1=C3=A1k?= Date: Tue, 5 Oct 2021 18:06:08 -0400 Subject: [PATCH] mesa: add missing unlock_texture into generate_texture_mipmap Fixes: 5a39938b0004de36ac55 "mesa: Throw an error for compressed glGenerateMipmap on GLES2 contexts." Reviewed-by: Timothy Arceri Part-of: --- src/mesa/main/genmipmap.c | 1 + 1 file changed, 1 insertion(+) diff --git a/src/mesa/main/genmipmap.c b/src/mesa/main/genmipmap.c index 8bf3b1a..bcb8ac9 100644 --- a/src/mesa/main/genmipmap.c +++ b/src/mesa/main/genmipmap.c @@ -160,6 +160,7 @@ generate_texture_mipmap(struct gl_context *ctx, */ if (ctx->API == API_OPENGLES2 && ctx->Version < 30 && _mesa_is_format_compressed(srcImage->TexFormat)) { + _mesa_unlock_texture(ctx, texObj); _mesa_error(ctx, GL_INVALID_OPERATION, "generate mipmaps on compressed texture"); return; } -- 2.7.4