diff options
author | Brian Gianforcaro <bgianf@serenityos.org> | 2021-05-13 01:01:38 -0700 |
---|---|---|
committer | Andreas Kling <kling@serenityos.org> | 2021-05-13 16:21:53 +0200 |
commit | 46ce7adf7b9e0101e1f8e4cb63757cf522d1ec62 (patch) | |
tree | 0ac4cc95877c99dbb1b8bffe050cb9a5dbdb5965 /Kernel/init.cpp | |
parent | 9375f3dc094fda351a7bb5bc6f78438b73beffdb (diff) | |
download | serenity-46ce7adf7b9e0101e1f8e4cb63757cf522d1ec62.zip |
Kernel: Make TCPSocket::create API OOM safe
Note that the changes to IPv4Socket::create are unfortunately needed as
the return type of TCPSocket::create and IPv4Socket::create don't match.
- KResultOr<NonnullRefPtr<TcpSocket>>>
vs
- KResultOr<NonnullRefPtr<Socket>>>
To handle this we are forced to manually decompose the KResultOr<T> and
return the value() and error() separately.
Diffstat (limited to 'Kernel/init.cpp')
0 files changed, 0 insertions, 0 deletions