[PATCH xserver] glx: Only flush indirect contexts in MakeCurrent (v2)

Michel Dänzer michel at daenzer.net
Wed Nov 15 09:05:12 UTC 2017


On 14/11/17 09:59 PM, Adam Jackson wrote:
> If the context is direct none of the GL commands were issued by this
> process, the server couldn't flush them even if it wanted to.
> 
> v2: Fix embarassingly obvious boolean inversion (Michel Dänzer)
> 
> Signed-off-by: Adam Jackson <ajax at redhat.com>
> ---
>  glx/glxcmds.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/glx/glxcmds.c b/glx/glxcmds.c
> index 241abc6a58..061acb7930 100644
> --- a/glx/glxcmds.c
> +++ b/glx/glxcmds.c
> @@ -626,7 +626,7 @@ DoMakeCurrent(__GLXclientState * cl,
>          /*
>           ** Flush the previous context if needed.
>           */
> -        Bool need_flush = GL_TRUE;
> +        Bool need_flush = !prevglxc->isDirect;
>  #ifdef GLX_CONTEXT_RELEASE_BEHAVIOR_ARB
>          if (prevglxc->releaseBehavior == GLX_CONTEXT_RELEASE_BEHAVIOR_NONE_ARB)
>              need_flush = GL_FALSE;
> 

Reviewed-by: Michel Dänzer <michel.daenzer at amd.com>


-- 
Earthling Michel Dänzer               |               http://www.amd.com
Libre software enthusiast             |             Mesa and X developer


More information about the xorg-devel mailing list