summaryrefslogtreecommitdiff
path: root/Kernel/Syscalls
diff options
context:
space:
mode:
authorBrian Gianforcaro <bgianf@serenityos.org>2021-04-24 15:27:32 -0700
committerAndreas Kling <kling@serenityos.org>2021-04-25 09:38:27 +0200
commit8d6e9fad40d493e6f2027cec37212956294a591f (patch)
tree71816f325880a99ef5b623d9795f2eded3d69ca7 /Kernel/Syscalls
parent0d5827f8652462715f6c2f91e2b91b2077547ae6 (diff)
downloadserenity-8d6e9fad40d493e6f2027cec37212956294a591f.zip
Kernel: Remove the now defunct `LOCKER(..)` macro.
Diffstat (limited to 'Kernel/Syscalls')
-rw-r--r--Kernel/Syscalls/hostname.cpp4
-rw-r--r--Kernel/Syscalls/uname.cpp2
2 files changed, 3 insertions, 3 deletions
diff --git a/Kernel/Syscalls/hostname.cpp b/Kernel/Syscalls/hostname.cpp
index 5ad02a905d..cc3b4b7f48 100644
--- a/Kernel/Syscalls/hostname.cpp
+++ b/Kernel/Syscalls/hostname.cpp
@@ -16,7 +16,7 @@ KResultOr<int> Process::sys$gethostname(Userspace<char*> buffer, ssize_t size)
REQUIRE_PROMISE(stdio);
if (size < 0)
return EINVAL;
- LOCKER(*g_hostname_lock, Lock::Mode::Shared);
+ Locker locker(*g_hostname_lock, Lock::Mode::Shared);
if ((size_t)size < (g_hostname->length() + 1))
return ENAMETOOLONG;
if (!copy_to_user(buffer, g_hostname->characters(), g_hostname->length() + 1))
@@ -31,7 +31,7 @@ KResultOr<int> Process::sys$sethostname(Userspace<const char*> hostname, ssize_t
return EPERM;
if (length < 0)
return EINVAL;
- LOCKER(*g_hostname_lock, Lock::Mode::Exclusive);
+ Locker locker(*g_hostname_lock, Lock::Mode::Exclusive);
if (length > 64)
return ENAMETOOLONG;
auto copied_hostname = copy_string_from_user(hostname, length);
diff --git a/Kernel/Syscalls/uname.cpp b/Kernel/Syscalls/uname.cpp
index 21fb2c8784..2e65239b60 100644
--- a/Kernel/Syscalls/uname.cpp
+++ b/Kernel/Syscalls/uname.cpp
@@ -15,7 +15,7 @@ KResultOr<int> Process::sys$uname(Userspace<utsname*> user_buf)
REQUIRE_PROMISE(stdio);
- LOCKER(*g_hostname_lock, Lock::Mode::Shared);
+ Locker locker(*g_hostname_lock, Lock::Mode::Shared);
if (g_hostname->length() + 1 > sizeof(utsname::nodename))
return ENAMETOOLONG;