summaryrefslogtreecommitdiff
path: root/quantum
diff options
context:
space:
mode:
Diffstat (limited to 'quantum')
-rw-r--r--quantum/led_matrix/led_matrix.c2
-rw-r--r--quantum/rgb_matrix/rgb_matrix.c2
2 files changed, 2 insertions, 2 deletions
diff --git a/quantum/led_matrix/led_matrix.c b/quantum/led_matrix/led_matrix.c
index 32788866c5..fe7f1f0394 100644
--- a/quantum/led_matrix/led_matrix.c
+++ b/quantum/led_matrix/led_matrix.c
@@ -219,7 +219,7 @@ void process_led_matrix(uint8_t row, uint8_t col, bool pressed) {
memcpy(&last_hit_buffer.y[0], &last_hit_buffer.y[led_count], LED_HITS_TO_REMEMBER - led_count);
memcpy(&last_hit_buffer.tick[0], &last_hit_buffer.tick[led_count], (LED_HITS_TO_REMEMBER - led_count) * 2); // 16 bit
memcpy(&last_hit_buffer.index[0], &last_hit_buffer.index[led_count], LED_HITS_TO_REMEMBER - led_count);
- last_hit_buffer.count--;
+ last_hit_buffer.count = LED_HITS_TO_REMEMBER - led_count;
}
for (uint8_t i = 0; i < led_count; i++) {
diff --git a/quantum/rgb_matrix/rgb_matrix.c b/quantum/rgb_matrix/rgb_matrix.c
index 789cd28605..624e851581 100644
--- a/quantum/rgb_matrix/rgb_matrix.c
+++ b/quantum/rgb_matrix/rgb_matrix.c
@@ -230,7 +230,7 @@ void process_rgb_matrix(uint8_t row, uint8_t col, bool pressed) {
memcpy(&last_hit_buffer.y[0], &last_hit_buffer.y[led_count], LED_HITS_TO_REMEMBER - led_count);
memcpy(&last_hit_buffer.tick[0], &last_hit_buffer.tick[led_count], (LED_HITS_TO_REMEMBER - led_count) * 2); // 16 bit
memcpy(&last_hit_buffer.index[0], &last_hit_buffer.index[led_count], LED_HITS_TO_REMEMBER - led_count);
- last_hit_buffer.count--;
+ last_hit_buffer.count = LED_HITS_TO_REMEMBER - led_count;
}
for (uint8_t i = 0; i < led_count; i++) {