[PATCH 09/37] Warning fixes in glx

Ian Romanick idr at freedesktop.org
Mon Nov 18 13:43:59 PST 2013


On 11/17/2013 12:01 AM, Keith Packard wrote:
> Signed-off-by: Keith Packard <keithp at keithp.com>
> ---
>  glx/glxdri2.c                | 2 +-
>  glx/glxdricommon.c           | 2 +-
>  glx/indirect_dispatch.c      | 1 +
>  glx/indirect_dispatch_swap.c | 3 +++
>  glx/indirect_program.c       | 2 ++
>  5 files changed, 8 insertions(+), 2 deletions(-)
> 
> diff --git a/glx/glxdri2.c b/glx/glxdri2.c
> index 1d74c8f..b245793 100644
> --- a/glx/glxdri2.c
> +++ b/glx/glxdri2.c
> @@ -508,7 +508,7 @@ create_driver_context(__GLXDRIcontext * context,
>          unsigned dri_err = 0;
>          unsigned major_ver;
>          unsigned minor_ver;
> -        uint32_t flags;
> +        uint32_t flags = 0;
>          int reset;
>          int api = __DRI_API_OPENGL;
>  
> diff --git a/glx/glxdricommon.c b/glx/glxdricommon.c
> index 1022c00..7a13c8e 100644
> --- a/glx/glxdricommon.c
> +++ b/glx/glxdricommon.c
> @@ -226,7 +226,7 @@ glxConvertConfigs(const __DRIcoreExtension * core,
>      }
>  
>      for (i = 0; configs[i]; i++) {
> -        int renderType = 0;
> +        unsigned int renderType = 0;
>          if (core->getConfigAttrib(configs[i], __DRI_ATTRIB_RENDER_TYPE,
>                                    &renderType)) {
>              if (render_type_is_pbuffer_only(renderType) &&
> diff --git a/glx/indirect_dispatch.c b/glx/indirect_dispatch.c
> index 1eee79a..d5fd233 100644
> --- a/glx/indirect_dispatch.c
> +++ b/glx/indirect_dispatch.c

This hunk and the rest in this patch are just going to make you sad:

/* DO NOT EDIT - This file generated automatically by glX_proto_recv.py (from Mesa) script */

> @@ -25,6 +25,7 @@
>   * SOFTWARE.
>   */
>  
> +#define NO_REALLY_GLX_PROTOTYPES
>  #include <inttypes.h>
>  #include "glxserver.h"
>  #include "indirect_size.h"
> diff --git a/glx/indirect_dispatch_swap.c b/glx/indirect_dispatch_swap.c
> index 9747514..5b0583e 100644
> --- a/glx/indirect_dispatch_swap.c
> +++ b/glx/indirect_dispatch_swap.c
> @@ -25,6 +25,7 @@
>   * SOFTWARE.
>   */
>  
> +#define NO_REALLY_GLX_PROTOTYPES
>  #include <inttypes.h>
>  #include "glxserver.h"
>  #include "indirect_size.h"
> @@ -81,6 +82,7 @@ bswap_ENUM(const void *src)
>      return x.ret;
>  }
>  
> +#if 0
>  static GLsync
>  bswap_CARD64(const void *src)
>  {
> @@ -92,6 +94,7 @@ bswap_CARD64(const void *src)
>      x.dst = bswap_64(*(uint64_t *) src);
>      return x.ret;
>  }
> +#endif
>  
>  static GLdouble
>  bswap_FLOAT64(const void *src)
> diff --git a/glx/indirect_program.c b/glx/indirect_program.c
> index db22d84..97ca241 100644
> --- a/glx/indirect_program.c
> +++ b/glx/indirect_program.c
> @@ -115,6 +115,7 @@ __glXDispSwap_GetProgramStringARB(struct __GLXclientStateRec *cl, GLbyte * pc)
>                                glGetProgramStringARB, True);
>  }
>  
> +#if 0
>  int
>  __glXDisp_GetProgramStringNV(struct __GLXclientStateRec *cl, GLbyte * pc)
>  {
> @@ -130,3 +131,4 @@ __glXDispSwap_GetProgramStringNV(struct __GLXclientStateRec *cl, GLbyte * pc)
>                                (PFNGLGETPROGRAMSTRINGARBPROC)glGetProgramStringNV,
>                                True);
>  }
> +#endif
> 



More information about the xorg-devel mailing list