1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-27 06:47:35 +00:00

Kernel: Use KResultOr<size_t> throughout the TTY subsystem

Previously the VirtualConsole::on_tty_write() method would return an
incorrect value when an error had occurred. This prompted me to
update the TTY subsystem to use KResultOr<size_t> everywhere.
This commit is contained in:
Gunnar Beutner 2021-06-16 15:20:35 +02:00 committed by Andreas Kling
parent a49a15cabf
commit 1c3346e3ce
9 changed files with 29 additions and 29 deletions

View file

@ -21,7 +21,7 @@ public:
unsigned index() const { return m_index; }
String pts_name() const;
ssize_t on_slave_write(const UserOrKernelBuffer&, ssize_t);
KResultOr<size_t> on_slave_write(const UserOrKernelBuffer&, size_t);
bool can_write_from_slave() const;
void notify_slave_closed(Badge<SlavePTY>);
bool is_closed() const { return m_closed; }