Skip to content

[libc] Potential wrong syscall number reference in linux_file.cpp #56122

@gytsen

Description

@gytsen

While browsing the File implementation of the new LLVM libc, I spotted what I believe to be a potential typo in the linux file implementation:

The code looks for the SYS__llseek syscall number in the #if defined statement on line 78. However, when doing the actual syscall, __llvm_libc::syscall is called with SYS__lseek as argument on line 80. If I'm not mistaken that is a typo and the call should read

long ret = __llvm_libc::syscall(SYS__llseek, lf->get_fd(), offset >> 32,
                                  offset, &result, whence);

instead.

If this is not the case, feel free to close this issue as not relevant.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions