diff options
author | Andreas Kling <kling@serenityos.org> | 2021-09-15 21:09:47 +0200 |
---|---|---|
committer | Andreas Kling <kling@serenityos.org> | 2021-09-15 21:09:47 +0200 |
commit | b6efd66d563a2d378e6b40a313c1b50808f78f0d (patch) | |
tree | 02793f3f8202944148125dbc0562dbc7a27cf430 /Kernel/Net/LocalSocket.cpp | |
parent | 422d725c79fdb95ff67292e1d6a04a6518d277ff (diff) | |
download | serenity-b6efd66d563a2d378e6b40a313c1b50808f78f0d.zip |
Kernel: Use move semantics in sys$sendfd()
Avoid an unnecessary NonnullRefPtr<OpenFileDescription> copy.
Diffstat (limited to 'Kernel/Net/LocalSocket.cpp')
-rw-r--r-- | Kernel/Net/LocalSocket.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Kernel/Net/LocalSocket.cpp b/Kernel/Net/LocalSocket.cpp index a6c7fb976e..f5dc0cc9f4 100644 --- a/Kernel/Net/LocalSocket.cpp +++ b/Kernel/Net/LocalSocket.cpp @@ -466,7 +466,7 @@ NonnullRefPtrVector<OpenFileDescription>& LocalSocket::sendfd_queue_for(const Op VERIFY_NOT_REACHED(); } -KResult LocalSocket::sendfd(const OpenFileDescription& socket_description, OpenFileDescription& passing_description) +KResult LocalSocket::sendfd(OpenFileDescription const& socket_description, NonnullRefPtr<OpenFileDescription> passing_description) { MutexLocker locker(mutex()); auto role = this->role(socket_description); |