MCPcopy Create free account
hub / github.com/F-Stack/f-stack / ff_socket

Function ff_socket

lib/ff_syscall_wrapper.c:908–923  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

906}
907
908int
909ff_socket(int domain, int type, int protocol)
910{
911 int rc;
912 struct socket_args sa;
913 sa.domain = domain == LINUX_AF_INET6 ? AF_INET6 : domain;
914 sa.type = linux2freebsd_socket_flags(type);
915 sa.protocol = protocol;
916 if ((rc = sys_socket(curthread, &sa)))
917 goto kern_fail;
918
919 return curthread->td_retval[0];
920kern_fail:
921 ff_os_errno(rc);
922 return (-1);
923}
924
925int
926ff_getsockopt(int s, int level, int optname, void *optval,

Callers 3

handle_ioctl_msgFunction · 0.70
handle_ipfw_msgFunction · 0.70
ff_ipfw_add_simple_v4Function · 0.70

Calls 3

sys_socketFunction · 0.85
ff_os_errnoFunction · 0.85

Tested by

no test coverage detected