summaryrefslogtreecommitdiffstats
path: root/src/mesa/main/shared.c
diff options
context:
space:
mode:
authorKenneth Graunke <[email protected]>2016-03-03 01:03:59 -0800
committerKenneth Graunke <[email protected]>2016-03-07 14:01:22 -0800
commit2f8a43586eef549105ad2f41ca9173c17b7e3440 (patch)
treed89f9be3e681384af8d5b62534acb98614a9cd5b /src/mesa/main/shared.c
parent8f99c1bbce629b9d3db0321e2d74414772615637 (diff)
mesa: Make GenerateMipmap check the target before finding an object.
If glGenerateMipmap was called with a bogus target, then it would pass that to _mesa_get_current_tex_object(), which would raise a _mesa_problem() telling people to file bugs. We'd then do the proper error checking, raise an error, and bail. Doing the check first avoids the _mesa_problem(). The DSA variant doesn't take a target parameter, so we leave the target validation exactly as it was in that case. Fixes one dEQP GLES2 test: dEQP-GLES2.functional.negative_api.texture.generatemipmap.invalid_target. v2: Rebase on Antia's recent patch to this area. Signed-off-by: Kenneth Graunke <[email protected]> Reviewed-by: Brian Paul <[email protected]> [v1] Reviewed-by: Matt Turner <[email protected]>
Diffstat (limited to 'src/mesa/main/shared.c')
0 files changed, 0 insertions, 0 deletions