diff options
author | Owen W. Taylor <otaylor@fishsoup.net> | 2015-09-03 16:12:06 -0400 |
---|---|---|
committer | Owen W. Taylor <otaylor@fishsoup.net> | 2015-09-03 16:13:50 -0400 |
commit | e3db4ab16a65be692c969088a6e1487dde305fc4 (patch) | |
tree | e48b063a87aa04c0b138394643dee45a9895cdb1 | |
parent | 614d6bd0f80ce336df7dca64e04746b057753f3b (diff) | |
download | mutter-e3db4ab16a65be692c969088a6e1487dde305fc4.tar.gz |
Avoid declaring variables in for loop to avoid upsetting older GCC
Older GCC only allows "for (int i" in explicit c99 mode - there's probably
no reason that we can't enable that, but avoiding the construct for
a fast fix.
-rw-r--r-- | src/wayland/meta-wayland-keyboard.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/wayland/meta-wayland-keyboard.c b/src/wayland/meta-wayland-keyboard.c index 8d136c9b9..c4836cb7b 100644 --- a/src/wayland/meta-wayland-keyboard.c +++ b/src/wayland/meta-wayland-keyboard.c @@ -485,7 +485,8 @@ meta_wayland_keyboard_update_key_state (MetaWaylandKeyboard *keyboard, { gboolean mods_changed = FALSE; - for (gint i = offset; i < key_vector_len * 8; i++) + int i; + for (i = offset; i < key_vector_len * 8; i++) { gboolean set = (key_vector[i/8] & (1 << (i % 8))) != 0; |