Lines Matching refs:sa

430 	struct sockaddr **sal, **psal, *sa;  local
442 sa = *sal;
445 sock = socket(sa->sa_family, socktype, 0);
451 switch (sa->sa_family) {
454 ((struct sockaddr_in6 *)sa)->sin6_family = sa->sa_family;
455 ((struct sockaddr_in6 *)sa)->sin6_port = htons(port);
460 ((struct sockaddr_in *)sa)->sin_family = sa->sa_family;
461 ((struct sockaddr_in *)sa)->sin_port = htons(port);
467 sa = NULL;
470 if (sa) {
498 n = bind(sock, sa, socklen);
527 …_network_address_with_port(const char *addr, zend_long addrlen, struct sockaddr *sa, socklen_t *sl) argument
533 struct sockaddr_in *in4 = (struct sockaddr_in*)sa;
538 struct sockaddr_in6 *in6 = (struct sockaddr_in6*)sa;
616 struct sockaddr *sa, socklen_t sl, argument
626 memcpy(*addr, sa, sl);
636 switch (sa->sa_family) {
639 buf = inet_ntoa(((struct sockaddr_in*)sa)->sin_addr);
642 buf, ntohs(((struct sockaddr_in*)sa)->sin_port));
649 …buf = (char*)inet_ntop(sa->sa_family, &((struct sockaddr_in6*)sa)->sin6_addr, (char *)&abuf, sizeo…
652 buf, ntohs(((struct sockaddr_in6*)sa)->sin6_port));
660 struct sockaddr_un *ua = (struct sockaddr_un*)sa;
685 php_sockaddr_storage sa; local
686 socklen_t sl = sizeof(sa);
687 memset(&sa, 0, sizeof(sa));
689 if (getpeername(sock, (struct sockaddr*)&sa, &sl) == 0) {
690 php_network_populate_name_from_sockaddr((struct sockaddr*)&sa, sl,
705 php_sockaddr_storage sa; local
706 socklen_t sl = sizeof(sa);
707 memset(&sa, 0, sizeof(sa));
709 if (getsockname(sock, (struct sockaddr*)&sa, &sl) == 0) {
710 php_network_populate_name_from_sockaddr((struct sockaddr*)&sa, sl,
742 php_sockaddr_storage sa; local
752 sl = sizeof(sa);
754 clisock = accept(srvsock, (struct sockaddr*)&sa, &sl);
757 php_network_populate_name_from_sockaddr((struct sockaddr*)&sa, sl,
797 struct sockaddr **sal, **psal, *sa; local
825 sa = *sal;
828 sock = socket(sa->sa_family, socktype, 0);
834 switch (sa->sa_family) {
838 ((struct sockaddr_in6 *)sa)->sin6_family = sa->sa_family;
839 ((struct sockaddr_in6 *)sa)->sin6_port = htons(port);
843 sa = NULL;
848 ((struct sockaddr_in *)sa)->sin_family = sa->sa_family;
849 ((struct sockaddr_in *)sa)->sin_port = htons(port);
855 sa = NULL;
858 if (sa) {
865 if (sa->sa_family == AF_INET) {
874 in4->sin_family = sa->sa_family;
889 in6->sin6_family = sa->sa_family;
929 n = php_network_connect_socket(sock, sa, socklen, asynchronous,