[waffle] [PATCH 33/33] examples/gl_basic: move variable declaration before code
Emil Velikov
emil.l.velikov at gmail.com
Mon Jul 7 10:28:40 PDT 2014
... this c99 feature finally works with msvc, but if the variable type is a typedef
things explode miserably. Until it works properly move the declaration.
Signed-off-by: Emil Velikov <emil.l.velikov at gmail.com>
---
examples/gl_basic.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/examples/gl_basic.c b/examples/gl_basic.c
index 0f4b5a3..d17a6af 100644
--- a/examples/gl_basic.c
+++ b/examples/gl_basic.c
@@ -523,6 +523,8 @@ main(int argc, char **argv)
struct waffle_context *ctx;
struct waffle_window *window;
+ GLint context_flags = 0;
+
#ifdef __APPLE__
cocoa_init();
#endif
@@ -621,7 +623,6 @@ main(int argc, char **argv)
if (!ok)
error_waffle();
- GLint context_flags = 0;
if (opts.context_forward_compatible || opts.context_debug) {
glGetIntegerv(GL_CONTEXT_FLAGS, &context_flags);
}
--
2.0.0
More information about the waffle
mailing list