From 750f8ec94e72a289881bff9f900fbe4ef97f688e Mon Sep 17 00:00:00 2001 From: Shihpin Tseng Date: Sat, 28 Oct 2017 17:57:36 +0800 Subject: Fix process_combo.c compile warning --- quantum/process_keycode/process_combo.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'quantum/process_keycode/process_combo.c') diff --git a/quantum/process_keycode/process_combo.c b/quantum/process_keycode/process_combo.c index 58d45add22..1addd72e5a 100644 --- a/quantum/process_keycode/process_combo.c +++ b/quantum/process_keycode/process_combo.c @@ -127,8 +127,12 @@ bool process_combo(uint16_t keycode, keyrecord_t *record) void matrix_scan_combo(void) { for (int i = 0; i < COMBO_COUNT; ++i) { + // Do not treat the (weak) key_combos too strict. + #pragma GCC diagnostic push + #pragma GCC diagnostic ignored "-Warray-bounds" combo_t *combo = &key_combos[i]; - if (combo->timer && + #pragma GCC diagnostic pop + if (combo->timer && combo->timer != COMBO_TIMER_ELAPSED && timer_elapsed(combo->timer) > COMBO_TERM) { -- cgit v1.2.3