summaryrefslogtreecommitdiff
path: root/Kernel/Net/LocalSocket.h
diff options
context:
space:
mode:
authorBrian Gianforcaro <b.gianfo@gmail.com>2020-08-07 02:29:05 -0700
committerAndreas Kling <kling@serenityos.org>2020-08-07 16:18:36 +0200
commit30b2c0dc85037c86d10ee14b46e4edfd42e785ec (patch)
tree601b0ec0510cabeb1c660313ad5489c80f965190 /Kernel/Net/LocalSocket.h
parent6920d5f4230ebcd4f1d29dc5d9288cf79861906f (diff)
downloadserenity-30b2c0dc85037c86d10ee14b46e4edfd42e785ec.zip
Kernel: Use Userspace<T> for the getsockopt syscall and Socket interface
The way getsockopt is implemented for socket types requires us to push down Userspace<T> using into those interfaces. This change does so, and utilizes proper copy implementations instead of the kind of haphazard pointer dereferencing that was occurring there before.
Diffstat (limited to 'Kernel/Net/LocalSocket.h')
-rw-r--r--Kernel/Net/LocalSocket.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/Kernel/Net/LocalSocket.h b/Kernel/Net/LocalSocket.h
index f01ce9bafa..60f5e2a52d 100644
--- a/Kernel/Net/LocalSocket.h
+++ b/Kernel/Net/LocalSocket.h
@@ -62,7 +62,7 @@ public:
virtual bool can_write(const FileDescription&, size_t) const override;
virtual KResultOr<size_t> sendto(FileDescription&, const void*, size_t, int, const sockaddr*, socklen_t) override;
virtual KResultOr<size_t> recvfrom(FileDescription&, void*, size_t, int flags, sockaddr*, socklen_t*) override;
- virtual KResult getsockopt(FileDescription&, int level, int option, void*, socklen_t*) override;
+ virtual KResult getsockopt(FileDescription&, int level, int option, Userspace<void*>, Userspace<socklen_t*>) override;
virtual KResult chown(FileDescription&, uid_t, gid_t) override;
virtual KResult chmod(FileDescription&, mode_t) override;