hare

The Hare programming language
git clone https://git.torresjrjr.com/hare.git
Log | Files | Refs | README | LICENSE

commit a122e46efe97d286f1a54a1924bec761626a160f
parent 0dbef0b3412b1e53870f438b3d2d93c36c061ec7
Author: Mykyta Holubakha <hilobakho@gmail.com>
Date:   Mon, 29 Mar 2021 21:26:42 +0300

rt: added getsockname syscall

Diffstat:
Mrt/+linux/syscalls.ha | 6++++++
1 file changed, 6 insertions(+), 0 deletions(-)

diff --git a/rt/+linux/syscalls.ha b/rt/+linux/syscalls.ha @@ -515,3 +515,9 @@ export fn ioctl(fd: int, req: u64, arg: nullable *void) (int | errno) = { return wrap_return(syscall3(SYS_ioctl, fd: u64, req, arg: uintptr: u64))?: int; }; + +export fn getsockname(sockfd: int, addr: nullable *sockaddr, addrlen: nullable *u32) (int | errno) = { + return wrap_return(syscall3(SYS_getsockname, + sockfd: u64, addr: uintptr: u64, addrlen: uintptr: u64))?: int; +}; +