[Mesa-dev] [PATCH 01/29] i965: Rename brwCreateContext's error parameter to dri_ctx_error.

Ian Romanick idr at freedesktop.org
Mon Sep 30 17:06:54 PDT 2013


On 09/27/2013 04:45 PM, Kenneth Graunke wrote:
> "error" is a very generic name.  dri_ctx_error is the name used in
> intelInitContext(), which is more specific.
> 
> Signed-off-by: Kenneth Graunke <kenneth at whitecape.org>
> ---
>  src/mesa/drivers/dri/i965/brw_context.c | 6 +++---
>  1 file changed, 3 insertions(+), 3 deletions(-)
> 
> diff --git a/src/mesa/drivers/dri/i965/brw_context.c b/src/mesa/drivers/dri/i965/brw_context.c
> index 230e0bb..75034d3 100644
> --- a/src/mesa/drivers/dri/i965/brw_context.c
> +++ b/src/mesa/drivers/dri/i965/brw_context.c
> @@ -281,7 +281,7 @@ brwCreateContext(int api,
>                   unsigned major_version,
>                   unsigned minor_version,
>                   uint32_t flags,
> -                 unsigned *error,
> +                 unsigned *dri_ctx_error,
>  	         void *sharedContextPrivate)

If you were to sneak in fixing this one line of bad whitespace, I'd look
the other way...

>  {
>     __DRIscreen *sPriv = driContextPriv->driScreenPriv;
> @@ -291,7 +291,7 @@ brwCreateContext(int api,
>     struct brw_context *brw = rzalloc(NULL, struct brw_context);
>     if (!brw) {
>        printf("%s: failed to alloc context\n", __FUNCTION__);
> -      *error = __DRI_CTX_ERROR_NO_MEMORY;
> +      *dri_ctx_error = __DRI_CTX_ERROR_NO_MEMORY;
>        return false;
>     }
>  
> @@ -309,7 +309,7 @@ brwCreateContext(int api,
>     if (!intelInitContext( brw, api, major_version, minor_version,
>                            mesaVis, driContextPriv,
>  			  sharedContextPrivate, &functions,
> -			  error)) {
> +			  dri_ctx_error)) {
>        intelDestroyContext(driContextPriv);
>        return false;
>     }
> 



More information about the mesa-dev mailing list