mirror of
https://github.com/RGBCube/serenity
synced 2025-07-27 07:47:35 +00:00
Kernel+LibC: Pass off_t to pread() via a pointer
`off_t` is a 64-bit signed integer, so passing it in a register on i686 is not the best idea. This fix gets us one step closer to making the LLVM port work.
This commit is contained in:
parent
7f8dc395c1
commit
648a139af3
3 changed files with 5 additions and 3 deletions
|
@ -296,7 +296,7 @@ ssize_t read(int fd, void* buf, size_t count)
|
|||
|
||||
ssize_t pread(int fd, void* buf, size_t count, off_t offset)
|
||||
{
|
||||
int rc = syscall(SC_pread, fd, buf, count, offset);
|
||||
int rc = syscall(SC_pread, fd, buf, count, &offset);
|
||||
__RETURN_WITH_ERRNO(rc, rc, -1);
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue