summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBrian Mock <brian@mockbrian.com>2020-05-09 20:14:07 -0700
committerFlorian Didron <fdidron@users.noreply.github.com>2020-06-12 17:00:27 +0900
commit0f2836bdac9d0cfffd18e7f7ff26e9eca7d14c7d (patch)
treebfbe8f7ec2c308481cc1f1cf4d41bc70c9f5b051
parenta45989a93e432dc43e3dc4928b4338615596732c (diff)
Fix off by one error with oled_write_raw_P (#9045)
-rw-r--r--drivers/oled/oled_driver.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/oled/oled_driver.c b/drivers/oled/oled_driver.c
index ce5c23cc40..eedaedcd36 100644
--- a/drivers/oled/oled_driver.c
+++ b/drivers/oled/oled_driver.c
@@ -479,7 +479,7 @@ void oled_write_ln_P(const char *data, bool invert) {
void oled_write_raw_P(const char *data, uint16_t size) {
if (size > OLED_MATRIX_SIZE) size = OLED_MATRIX_SIZE;
for (uint16_t i = 0; i < size; i++) {
- uint8_t c = pgm_read_byte(++data);
+ uint8_t c = pgm_read_byte(data++);
if (oled_buffer[i] == c) continue;
oled_buffer[i] = c;
oled_dirty |= (1 << (i / OLED_BLOCK_SIZE));