this repo has no description
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

Use the right syscall for recvfrom + crash fix

+3 -2
+3 -2
src/kernel/emulation/linux/network/recvfrom.c
··· 2 2 #include "../base.h" 3 3 #include "../errno.h" 4 4 #include <asm/unistd.h> 5 + #include <stddef.h> 5 6 #include "socket.h" 6 7 #include "duct.h" 7 8 ··· 25 26 ret = LINUX_SYSCALL(__NR_socketcall, LINUX_SYS_RECVFROM, ((long[6]) { fd, buf, len, 26 27 flags, from, socklen })); 27 28 #else 28 - ret = LINUX_SYSCALL(__NR_connect, fd, buf, len, flags, from, socklen); 29 + ret = LINUX_SYSCALL(__NR_recvfrom, fd, buf, len, flags, from, socklen); 29 30 #endif 30 31 31 32 if (ret < 0) 32 33 ret = errno_linux_to_bsd(ret); 33 - else 34 + else if (from != NULL) 34 35 { 35 36 fixed = (struct sockaddr_fixup*) from; 36 37 fixed->bsd_family = sfamily_linux_to_bsd(fixed->linux_family);