mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-08-11 18:50:50 +00:00
Kernel: Make File::write() and File::read() return KResultOr<size_t>
Instead of returning a ssize_t where negative values mean error, we now return KResultOr<size_t> and use the error state to report errors exclusively.
This commit is contained in:
parent
58feebeed2
commit
7a3ab6c517
Notes:
sideshowbarker
2024-07-19 04:18:56 +09:00
Author: https://github.com/awesomekling
Commit: 7a3ab6c517
58 changed files with 223 additions and 229 deletions
|
@ -43,8 +43,8 @@ private:
|
|||
virtual const char* class_name() const override { return "UDPSocket"; }
|
||||
static Lockable<HashMap<u16, UDPSocket*>>& sockets_by_port();
|
||||
|
||||
virtual int protocol_receive(const KBuffer&, void* buffer, size_t buffer_size, int flags) override;
|
||||
virtual int protocol_send(const void*, size_t) override;
|
||||
virtual KResultOr<size_t> protocol_receive(const KBuffer&, void* buffer, size_t buffer_size, int flags) override;
|
||||
virtual KResultOr<size_t> protocol_send(const void*, size_t) override;
|
||||
virtual KResult protocol_connect(FileDescription&, ShouldBlock) override;
|
||||
virtual int protocol_allocate_local_port() override;
|
||||
virtual KResult protocol_bind() override;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue