Kernel: Use Userspace<T> for the gethostname syscall

This commit is contained in:
Brian Gianforcaro 2020-08-09 12:51:41 -07:00 committed by Andreas Kling
parent b069d757a3
commit 1d9554f470
Notes: sideshowbarker 2024-07-19 04:05:48 +09:00
2 changed files with 2 additions and 2 deletions

View file

@ -250,7 +250,7 @@ public:
int sys$clock_gettime(clockid_t, Userspace<timespec*>);
int sys$clock_settime(clockid_t, Userspace<const timespec*>);
int sys$clock_nanosleep(Userspace<const Syscall::SC_clock_nanosleep_params*>);
int sys$gethostname(char*, ssize_t);
int sys$gethostname(Userspace<char*>, ssize_t);
int sys$sethostname(const char*, ssize_t);
int sys$uname(utsname*);
int sys$readlink(Userspace<const Syscall::SC_readlink_params*>);

View file

@ -31,7 +31,7 @@ namespace Kernel {
extern String* g_hostname;
extern Lock* g_hostname_lock;
int Process::sys$gethostname(char* buffer, ssize_t size)
int Process::sys$gethostname(Userspace<char*> buffer, ssize_t size)
{
REQUIRE_PROMISE(stdio);
if (size < 0)