use enabled macro for mapper setting

master
Scott Lahteine 8 years ago
parent e6e4d4062d
commit 0432613ad7

@ -2469,10 +2469,10 @@ void lcd_init() {
int lcd_strlen(const char* s) { int lcd_strlen(const char* s) {
int i = 0, j = 0; int i = 0, j = 0;
while (s[i]) { while (s[i]) {
#ifdef MAPPER_NON #if ENABLED(MAPPER_NON)
j++; j++;
#else #else
if ((s[i] & 0xc0) != 0x80) j++; if ((s[i] & 0xC0u) != 0x80u) j++;
#endif #endif
i++; i++;
} }
@ -2482,10 +2482,10 @@ int lcd_strlen(const char* s) {
int lcd_strlen_P(const char* s) { int lcd_strlen_P(const char* s) {
int j = 0; int j = 0;
while (pgm_read_byte(s)) { while (pgm_read_byte(s)) {
#ifdef MAPPER_NON #if ENABLED(MAPPER_NON)
j++; j++;
#else #else
if ((pgm_read_byte(s) & 0xc0) != 0x80) j++; if ((pgm_read_byte(s) & 0xC0u) != 0x80u) j++;
#endif #endif
s++; s++;
} }

Loading…
Cancel
Save