diff options
Diffstat (limited to 'src/mesa/main/teximage.c')
-rw-r--r-- | src/mesa/main/teximage.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/mesa/main/teximage.c b/src/mesa/main/teximage.c index 3b309abbe14..cd451138b1c 100644 --- a/src/mesa/main/teximage.c +++ b/src/mesa/main/teximage.c @@ -4586,7 +4586,8 @@ compressed_subtexture_target_check(struct gl_context *ctx, GLenum target, * are valid here, which they are not, but of course not mentioned by * core spec. */ - if (target != GL_TEXTURE_2D_ARRAY && target != GL_TEXTURE_CUBE_MAP_ARRAY) { + if (targetOK && target != GL_TEXTURE_2D_ARRAY && + target != GL_TEXTURE_CUBE_MAP_ARRAY) { bool invalidformat; switch (format) { /* These came from _mesa_is_compressed_format in glformats.c. */ |