mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-06-04 17:33:04 +00:00
Kernel: Have the open() syscall take an explicit path length parameter.
Instead of computing the path length inside the syscall handler, let the caller do that work. This allows us to implement to new variants of open() and creat(), called open_with_path_length() and creat_with_path_length(). These are suitable for use with e.g StringView.
This commit is contained in:
parent
fc4022d173
commit
c110cf193d
Notes:
sideshowbarker
2024-07-19 13:21:47 +09:00
Author: https://github.com/awesomekling
Commit: c110cf193d
9 changed files with 40 additions and 9 deletions
|
@ -85,7 +85,7 @@ static u32 handle(RegisterDump& regs, u32 function, u32 arg1, u32 arg2, u32 arg3
|
|||
case Syscall::SC_getcwd:
|
||||
return current->process().sys$getcwd((char*)arg1, (size_t)arg2);
|
||||
case Syscall::SC_open:
|
||||
return current->process().sys$open((const char*)arg1, (int)arg2, (mode_t)arg3);
|
||||
return current->process().sys$open((const SC_open_params*)arg1);
|
||||
case Syscall::SC_write:
|
||||
return current->process().sys$write((int)arg1, (const u8*)arg2, (ssize_t)arg3);
|
||||
case Syscall::SC_close:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue