Lines Matching refs:bsd_socket

56 # define IS_INVALID_SOCKET(a)	(a->bsd_socket < 0)
400 php_sock->bsd_socket = -1; /* invalid socket */ in php_create_socket()
416 close(php_sock->bsd_socket); in php_destroy_socket()
446 sock->bsd_socket = socket(PF_INET, SOCK_STREAM, 0);
457 if (bind(sock->bsd_socket, (struct sockaddr *)&la, sizeof(la)) != 0) {
459 close(sock->bsd_socket);
464 if (listen(sock->bsd_socket, backlog) != 0) {
466 close(sock->bsd_socket);
481 out_sock->bsd_socket = accept(in_sock->bsd_socket, la, la_len);
507 m = fcntl(sock->bsd_socket, F_GETFL);
539 m = recv(sock->bsd_socket, (void *) t, 1, flags);
797 PHP_SAFE_FD_SET(php_sock->bsd_socket, fds);
798 if (php_sock->bsd_socket > *max_fd) {
799 *max_fd = php_sock->bsd_socket;
825 if (PHP_SAFE_FD_ISSET(php_sock->bsd_socket, fds)) {
997 if (php_set_sock_blocking(php_sock->bsd_socket, 0) == SUCCESS) {
1037 if (php_set_sock_blocking(php_sock->bsd_socket, 1) == SUCCESS) {
1063 if (listen(php_sock->bsd_socket, backlog) != 0) {
1125 retval = write(php_sock->bsd_socket, str, MIN(length, str_len));
1127 retval = send(php_sock->bsd_socket, str, min(length, str_len), 0);
1167 retval = recv(php_sock->bsd_socket, ZSTR_VAL(tmpbuf), length, 0);
1226 if (getsockname(php_sock->bsd_socket, sa, &salen) != 0) {
1309 if (getpeername(php_sock->bsd_socket, sa, &salen) < 0) {
1389 php_sock->bsd_socket = socket(arg1, arg2, arg3);
1445 retval = connect(php_sock->bsd_socket, (struct sockaddr *)&sin6, sizeof(struct sockaddr_in6));
1464 retval = connect(php_sock->bsd_socket, (struct sockaddr *)&sin, sizeof(struct sockaddr_in));
1478 retval = connect(php_sock->bsd_socket, (struct sockaddr *) &s_un,
1547 retval = bind(php_sock->bsd_socket, (struct sockaddr *) sa,
1563 retval = bind(php_sock->bsd_socket, (struct sockaddr *)sa, sizeof(struct sockaddr_in));
1578 retval = bind(php_sock->bsd_socket, (struct sockaddr *)sa, sizeof(struct sockaddr_in6));
1621 if ((retval = recv(php_sock->bsd_socket, ZSTR_VAL(recv_buf), len, flags)) < 1) {
1662 retval = send(php_sock->bsd_socket, buf, (buf_len < len ? buf_len : len), flags);
1710 …retval = recvfrom(php_sock->bsd_socket, ZSTR_VAL(recv_buf), arg3, arg4, (struct sockaddr *)&s_un, …
1737 …retval = recvfrom(php_sock->bsd_socket, ZSTR_VAL(recv_buf), arg3, arg4, (struct sockaddr *)&sin, (…
1768 …retval = recvfrom(php_sock->bsd_socket, ZSTR_VAL(recv_buf), arg3, arg4, (struct sockaddr *)&sin6, …
1830 …retval = sendto(php_sock->bsd_socket, buf, (len > buf_len) ? buf_len : len, flags, (struct sockadd…
1846 …retval = sendto(php_sock->bsd_socket, buf, (len > buf_len) ? buf_len : len, flags, (struct sockadd…
1862 …retval = sendto(php_sock->bsd_socket, buf, (len > buf_len) ? buf_len : len, flags, (struct sockadd…
1908 if (getsockopt(php_sock->bsd_socket, level, optname, (char*)&if_addr, &optlen) != 0) {
1936 if (getsockopt(php_sock->bsd_socket, level, optname, (char*)&linger_val, &optlen) != 0) {
1951 if (getsockopt(php_sock->bsd_socket, level, optname, (char*)&tv, &optlen) != 0) {
1958 if (getsockopt(php_sock->bsd_socket, level, optname, (char*)&timeout, &optlen) != 0) {
1976 if (getsockopt(php_sock->bsd_socket, level, optname, (char*)&other_val, &optlen) != 0) {
2124 retval = setsockopt(php_sock->bsd_socket, level, optname, opt_ptr, optlen);
2176 php_sock[0]->bsd_socket = fds_array[0];
2177 php_sock[1]->bsd_socket = fds_array[1];
2213 if (shutdown(php_sock->bsd_socket, how_shutdown) != 0) {
2283 retsock->bsd_socket = socket;
2396 getsockopt(socket->bsd_socket, SOL_SOCKET, SO_TYPE, (char *) &protoid, &protoidlen);
2402 getsockopt(socket->bsd_socket, SOL_SOCKET, SO_PROTOCOL, (char *) &protoid, &protoidlen);
2418 getsockopt(socket->bsd_socket, SOL_SOCKET, SO_TYPE, (char *) &type, &typelen);
2439 stream = php_stream_sock_open_from_socket(socket->bsd_socket, 0);
2448 stream_data->socket = socket->bsd_socket;