Lines Matching refs:netfd
72 static int sockfd, netfd[MAX_CONNECTION] = {[0 ... MAX_CONNECTION-1] = -1};
224 if (netfd[i] >= 0)
225 close(netfd[i]);
397 netfd[i] = -1;
410 if (netfd[i] < 0)
419 netfd[i] = accept(sockfd, (struct sockaddr *)&addr, &addr_len);
420 if (netfd[i] < 0) {
425 fprintf(stderr, _("accepted[%d]\n"), netfd[i]);
476 netfd[0] = fd;
500 if (netfd[i] >= 0) {
501 pollfds[width].fd = netfd[i];
524 if (netfd[i] < 0)
527 if (copy_remote_to_local(netfd[i])) {
528 netfd[i] = -1;
547 if (netfd[i] >= 0) {
548 ssize_t wrlen = write(netfd[i], writebuf, cur_wrlen);