Lines Matching refs:sockfd
181 static SOCKET sockfd; /* fd socket is opened on */ variable
507 closesocket(sockfd); in openhost()
537 sockfd = socket(ai->ai_family, SOCK_DGRAM, 0); in openhost()
538 if (sockfd == INVALID_SOCKET) { in openhost()
548 if (setsockopt(sockfd, SOL_SOCKET, SO_RCVBUF, in openhost()
556 if (connect(sockfd, (struct sockaddr *)&hostaddr, in openhost()
559 if (connect(sockfd, ai->ai_addr, ai->ai_addrlen) == -1) in openhost()
584 if (send(sockfd, xdata, xdatalen, 0) == -1) { in sendpkt()
665 FD_SET(sockfd, &fds); in getresponse()
666 n = select(sockfd+1, &fds, NULL, NULL, &tvo); in getresponse()
678 n = recv(sockfd, (char *)&rpkt, sizeof(rpkt), 0); in getresponse()
709 n = recv(sockfd, (char *)&rpkt, sizeof(rpkt), 0); in getresponse()
1022 FD_SET(sockfd, &fds); in doquery()
1023 res = select(sockfd+1, &fds, NULL, NULL, &tvzero); in doquery()
1029 (void) recv(sockfd, junk, sizeof junk, 0); in doquery()
1890 closesocket(sockfd); in quit()