Lines Matching refs:sa
370 sock = xsocket(lsa->u.sa.sa_family, tcp ? SOCK_STREAM : SOCK_DGRAM, 0); in tcpudpsvd_main()
373 xbind(sock, &lsa->u.sa, sa_len); in tcpudpsvd_main()
391 char *addr = xmalloc_sockaddr2dotted(&lsa->u.sa); in tcpudpsvd_main()
419 conn = accept(sock, &remote.u.sa, &remote.len); in tcpudpsvd_main()
425 &remote.u.sa, &local.u.sa, sa_len); in tcpudpsvd_main()
438 remote_addr = xmalloc_sockaddr2dotted_noport(&remote.u.sa); in tcpudpsvd_main()
461 sock = xsocket(lsa->u.sa.sa_family, SOCK_DGRAM, 0); in tcpudpsvd_main()
466 xconnect(0, &remote.u.sa, sa_len); in tcpudpsvd_main()
471 xbind(sock, &lsa->u.sa, sa_len); in tcpudpsvd_main()
486 set_nport(&localp->u.sa, htons(local_port)); in tcpudpsvd_main()
487 xmove_fd(xsocket(localp->u.sa.sa_family, SOCK_DGRAM, 0), 0); in tcpudpsvd_main()
489 xbind(0, &localp->u.sa, localp->len); in tcpudpsvd_main()
521 free_me0 = remote_addr = xmalloc_sockaddr2dotted(&remote.u.sa); in tcpudpsvd_main()
523 free_me1 = remote_hostname = xmalloc_sockaddr2host_noport(&remote.u.sa); in tcpudpsvd_main()
533 getsockname(0, &local.u.sa, &local.len); in tcpudpsvd_main()
535 local_addr = xmalloc_sockaddr2dotted(&local.u.sa); in tcpudpsvd_main()
539 free_me2 = local_hostname = xmalloc_sockaddr2host_noport(&local.u.sa); in tcpudpsvd_main()
570 if (tcp && getsockopt(0, SOL_IP, SO_ORIGINAL_DST, &local.u.sa, &local.len) == 0) { in tcpudpsvd_main()
571 char *addr = xmalloc_sockaddr2dotted(&local.u.sa); in tcpudpsvd_main()