]> git.ipfire.org Git - thirdparty/plymouth.git/commit
terminal: Add API for flushing input buffer
authorRay Strode <rstrode@redhat.com>
Thu, 17 Nov 2022 15:01:34 +0000 (10:01 -0500)
committerRay Strode <rstrode@redhat.com>
Tue, 29 Nov 2022 14:22:06 +0000 (09:22 -0500)
commit288d0aca0289911d1bf691d03775334b18d019e7
tree2a54eb6f27427516e50e742276e7722846fb45f5
parentdacf2dd9f33b2b357977ba5fe6ba8c2979e5b330
terminal: Add API for flushing input buffer

In the future we're going to start reading keyboard input from
/dev/input instead of the tty. When that happens, input will
still be sent by the kernel to the tty.

This input would eventually back up and overflow.

To address that problem before it exists, this commit adds a new
API, ply_terminal_flush_input, that will drain the input buffer
on demand.

We can later use that API to keep the tty from backing up.
src/libply-splash-core/ply-terminal.c
src/libply-splash-core/ply-terminal.h