Bug 31067

Summary: main/enable.c:56: warning: ‘flag’ may be used uninitialized in this function
Product: Mesa Reporter: Vinson Lee <vlee>
Component: Mesa coreAssignee: Brian Paul <brianp>
Status: CLOSED FIXED QA Contact:
Severity: normal    
Priority: medium    
Version: git   
Hardware: All   
OS: All   
Whiteboard:
i915 platform: i915 features:

Description Vinson Lee 2010-10-23 17:32:15 UTC
mesa: d8740b77ac30298c1742107e2afc4edabca562f0 (master)

main/enable.c: In function ‘client_state’:
main/enable.c:56: warning: ‘flag’ may be used uninitialized in this function

src/mesa/main/enable.c
    52  static void
    53  client_state(struct gl_context *ctx, GLenum cap, GLboolean state)
    54  {
    55     struct gl_array_object *arrayObj = ctx->Array.ArrayObj;
    56     GLuint flag;
    57     GLboolean *var;
...
   127        /* GL_NV_primitive_restart */
   128        case GL_PRIMITIVE_RESTART_NV:
   129           if (!ctx->Extensions.NV_primitive_restart) {
   130              goto invalid_enum_error;
   131           }
   132           var = &ctx->Array.PrimitiveRestart;
   133           break;
Comment 1 Brian Paul 2010-10-25 08:18:28 UTC
Fixed w/ commit 2701eb342b358da638b8c0f281c791c2b16b300b
Comment 2 Vinson Lee 2010-10-25 17:52:16 UTC
mesa: 2d2bafdb30110e83b7e14017326a454d7e7f37f3 (master)

Verified fixed.

Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.