1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-27 19:37:34 +00:00

LibC+Kernel: Switch off_t to 64 bits

This commit is contained in:
Jean-Baptiste Boric 2021-03-13 22:02:54 +01:00 committed by Andreas Kling
parent b05b4d4b24
commit 7a079f7780
7 changed files with 23 additions and 13 deletions

View file

@ -55,7 +55,7 @@ typedef int id_t;
typedef __WINT_TYPE__ wint_t;
typedef uint32_t ino_t;
typedef ssize_t off_t;
typedef int64_t off_t;
typedef uint32_t dev_t;
typedef uint16_t mode_t;

View file

@ -440,8 +440,8 @@ ssize_t readlink(const char* path, char* buffer, size_t size)
off_t lseek(int fd, off_t offset, int whence)
{
int rc = syscall(SC_lseek, fd, offset, whence);
__RETURN_WITH_ERRNO(rc, rc, -1);
int rc = syscall(SC_lseek, fd, &offset, whence);
__RETURN_WITH_ERRNO(rc, offset, -1);
}
int link(const char* old_path, const char* new_path)
@ -633,7 +633,7 @@ char* getlogin()
int ftruncate(int fd, off_t length)
{
int rc = syscall(SC_ftruncate, fd, length);
int rc = syscall(SC_ftruncate, fd, &length);
__RETURN_WITH_ERRNO(rc, rc, -1);
}