[Mesa-dev] [PATCH 2/2] mesa: fold always true conditional

Brian Paul brianp at vmware.com
Fri Nov 11 17:00:54 UTC 2016


On 11/11/2016 09:43 AM, Emil Velikov wrote:
> From: Emil Velikov <emil.velikov at collabora.com>
>
> Signed-off-by: Emil Velikov <emil.velikov at collabora.com>
> ---
>   src/mesa/main/context.c | 6 ++----
>   1 file changed, 2 insertions(+), 4 deletions(-)
>
> diff --git a/src/mesa/main/context.c b/src/mesa/main/context.c
> index 80bee16..bd4551e 100644
> --- a/src/mesa/main/context.c
> +++ b/src/mesa/main/context.c
> @@ -1696,10 +1696,8 @@ _mesa_make_current( struct gl_context *newCtx,
>             */
>   	 newCtx->NewState |= _NEW_BUFFERS;
>
> -         if (drawBuffer) {
> -            _mesa_check_init_viewport(newCtx,
> -                                      drawBuffer->Width, drawBuffer->Height);
> -         }
> +         _mesa_check_init_viewport(newCtx,
> +                                   drawBuffer->Width, drawBuffer->Height);
>         }
>
>         if (newCtx->FirstTimeCurrent) {
>

Reviewed-by: Brian Paul <brianp at vmware.com>



More information about the mesa-dev mailing list