From 1c3346e3ceb442de8d52a8f9f756a4c0c737b294 Mon Sep 17 00:00:00 2001 From: Gunnar Beutner Date: Wed, 16 Jun 2021 15:20:35 +0200 Subject: Kernel: Use KResultOr 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 everywhere. --- Kernel/TTY/MasterPTY.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Kernel/TTY/MasterPTY.h') diff --git a/Kernel/TTY/MasterPTY.h b/Kernel/TTY/MasterPTY.h index ffc4bf9cb3..abc117b95b 100644 --- a/Kernel/TTY/MasterPTY.h +++ b/Kernel/TTY/MasterPTY.h @@ -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 on_slave_write(const UserOrKernelBuffer&, size_t); bool can_write_from_slave() const; void notify_slave_closed(Badge); bool is_closed() const { return m_closed; } -- cgit v1.2.3