[Piglit] [PATCH 2/2] glx-swap-event: Silence declaration-after-statement warning.
jfonseca at vmware.com
jfonseca at vmware.com
Tue Jan 17 11:29:11 PST 2012
From: José Fonseca <jfonseca at vmware.com>
This seems to be the only outstanding use of this feature in the
source.
---
tests/glx/glx-swap-event.c | 3 ++-
1 files changed, 2 insertions(+), 1 deletions(-)
diff --git a/tests/glx/glx-swap-event.c b/tests/glx/glx-swap-event.c
index 313c565..3304d2c 100644
--- a/tests/glx/glx-swap-event.c
+++ b/tests/glx/glx-swap-event.c
@@ -129,6 +129,7 @@ draw_frame(Display *dpy, Window win)
if (tRate0 < 0.0)
tRate0 = t;
if (t - tRate0 >= 3.0) {
+ GLfloat seconds;
if (interval_diff) {
if (message_count & 0x1) {
ret = (*pglXSwapIntervalMESA)(1);
@@ -145,7 +146,7 @@ draw_frame(Display *dpy, Window win)
}
}
message_count++;
- GLfloat seconds = t - tRate0;
+ seconds = t - tRate0;
if ( (time_val / frames) < 0.0016 ) {
// 0.0016 <=> 60Hz * 10 or 100Hz * 6
async_swap=1;
--
1.7.7.3
More information about the Piglit
mailing list