[Mesa-dev] [PATCH 3/4] mesa/es: Validate glMapBuffer access in Mesa code rather than the ES wrapper
Eric Anholt
eric at anholt.net
Fri Aug 24 13:32:12 PDT 2012
Ian Romanick <idr at freedesktop.org> writes:
> <template name="UnmapBuffer" direction="get">
> diff --git a/src/mesa/main/bufferobj.c b/src/mesa/main/bufferobj.c
> index fb30d1a..6ad0787 100644
> --- a/src/mesa/main/bufferobj.c
> +++ b/src/mesa/main/bufferobj.c
> @@ -1039,7 +1039,7 @@ _mesa_BufferDataARB(GLenum target, GLsizeiptrARB size,
> case GL_STATIC_COPY_ARB:
> case GL_DYNAMIC_READ_ARB:
> case GL_DYNAMIC_COPY_ARB:
> - valid_usage = (ctx->API == API_OPENGL);
> + valid_usage = _mesa_is_desktop_gl(ctx) || _mesa_is_gles3(ctx);
> break;
This hunk should be in 2/4.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 197 bytes
Desc: not available
URL: <http://lists.freedesktop.org/archives/mesa-dev/attachments/20120824/76c54e8b/attachment.pgp>
More information about the mesa-dev
mailing list