mesa: return INVALID_VALUE from ClientWaitSync if flags contains an unsupported flag
authorMatt Turner <mattst88@gmail.com>
Tue, 13 Nov 2012 21:26:11 +0000 (13:26 -0800)
committerMatt Turner <mattst88@gmail.com>
Thu, 15 Nov 2012 23:21:28 +0000 (15:21 -0800)
Fixes gles3conform's sync_error_clientwaitsync_flags test.
Reviewed-by: Chad Versace <chad.versace@linux.intel.com>
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
src/mesa/main/syncobj.c

index 1d178950c084b2e1fa200c44190b1b3c5d912817..c4fe34478876397852869460919d18480f7e9c59 100644 (file)
@@ -308,7 +308,7 @@ _mesa_ClientWaitSync(GLsync sync, GLbitfield flags, GLuint64 timeout)
    }
 
    if ((flags & ~GL_SYNC_FLUSH_COMMANDS_BIT) != 0) {
-      _mesa_error(ctx, GL_INVALID_ENUM, "glClientWaitSync(flags=0x%x)", flags);
+      _mesa_error(ctx, GL_INVALID_VALUE, "glClientWaitSync(flags=0x%x)", flags);
       return GL_WAIT_FAILED;
    }