»Home
»Examples
»Invocation
»Runtime Library
»Python Bindings
»Known Issues
Shellcode Compiler
A custom shellcode compiler for Binary Ninja

# __syscall2

    long __syscall2(long& ret2, long num, ...);

Issues system call number num on the target platform, expecting two return values instead of one. Any additional arguments are passed directly to the system call. Returns the first half of the result of the system call, with the second half of the result placed into the ret2 variable.

| On platforms that set a processor flag on error, such as FreeBSD, the __syscall function will return the negation of the error code on error. This is to allow for unified behaviour across different platforms. For example, checking the result of the open call for -ENOENT will work across all supported UNIX-based platforms.

## See also

syscall