mirror of
https://github.com/Matiasus/SSD1306.git
synced 2024-10-03 18:18:46 -04:00
Fix issue - SSD1306_DrawPixel / replace && by || in out of range
Thanks to Bill Pringlemeir
This commit is contained in:
parent
ce135fab47
commit
c07b04bac0
@ -519,7 +519,7 @@ uint8_t SSD1306_DrawPixel (uint8_t x, uint8_t y)
|
||||
uint8_t pixel = 0;
|
||||
|
||||
// if out of range
|
||||
if ((x > MAX_X) && (y > MAX_Y)) {
|
||||
if ((x > MAX_X) || (y > MAX_Y)) {
|
||||
// out of range
|
||||
return SSD1306_ERROR;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user