Skip to content

Commit 87c2941

Browse files
committed
write() should return 0 if the character is being ignored
1 parent 977e7b4 commit 87c2941

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/Keyboard.cpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -313,7 +313,8 @@ void Keyboard_::releaseAll(void)
313313
size_t Keyboard_::write(uint8_t c)
314314
{
315315
if (c == '\r') {
316-
return c;
316+
// ignore it
317+
return 0;
317318
}
318319
if (c == '\n') {
319320
c = KEY_RETURN;

0 commit comments

Comments
 (0)