Lines Matching refs:htp

68 	struct hosttbl *htp;
187 htp = findhost(msg->tsp_name);
188 if (htp == 0) {
194 if (htp->seq == msg->tsp_seq)
196 htp->seq = msg->tsp_seq;
197 if (!htp->good) {
266 htp = addmach(answer->tsp_name,&from,ntp);
268 msg = acksend(&to, &htp->addr, htp->name,
269 TSP_ACK, 0, htp->noanswer);
273 htp->name);
303 htp = addmach(msg->tsp_name, &from,fromnet);
306 answer = acksend(&to, &htp->addr, htp->name,
311 htp->name, inet_ntoa(htp->addr.sin_addr));
312 (void)remmach(htp);
390 struct hosttbl *htp;
398 for (htp = self.l_fwd; htp != &self; htp = htp->l_fwd) {
399 if (htp->noanswer != 0) {
401 htp->name,
402 &htp->addr,0);
405 htp->name,
406 &htp->addr,0);
412 htp->delta = HOSTDOWN;
413 if (++htp->noanswer >= LOSTHOST) {
417 htp->name);
420 htp = remmach(htp);
423 htp->delta = measure_delta;
463 struct hosttbl *htp;
472 for (htp = self.l_fwd; htp != &self; htp = htp->l_fwd) {
478 answer = acksend(&to, &htp->addr, htp->name,
479 TSP_ACK, 0, htp->noanswer);
485 "no reply to SETTIME from %s", htp->name);
486 if (++htp->noanswer >= LOSTHOST) {
490 htp->name);
493 htp = remmach(htp);
505 struct hosttbl *htp;
518 htp = self.l_fwd;
520 for (i = 1; i <= slvcount; i++, htp = htp->l_fwd) {
521 l = strlen(htp->name) + 1;
527 fprintf(fd, " %s", htp->name);
541 struct hosttbl *htp;
549 htp = newhost_hash;
550 if (htp->name[0] == '\0')
553 if (!strcmp(name, htp->name))
554 return(htp);
555 htp = htp->h_fwd;
556 } while (htp != newhost_hash);
650 remmach(struct hosttbl *htp)
655 fprintf(fd, "remove %s\n", htp->name);
658 htp->l_fwd->l_bak = lprv = htp->l_bak;
659 htp->l_bak->l_fwd = htp->l_fwd;
660 htp->h_fwd->h_bak = htp->h_bak;
661 htp->h_bak->h_fwd = hnxt = htp->h_fwd;
664 if (htp->head && hnxt != htp) {
666 lprv = htp;
673 f->h_bak = htp;
674 b->h_fwd = htp;
677 f->l_bak = htp;
678 b->l_fwd = htp;
680 bcopy(hnxt, htp, sizeof(*htp));
683 lasthfree = htp;
703 struct hosttbl *htp;
707 for (htp = self.l_fwd; htp != &self; htp = htp->l_fwd) {
708 if (ntp == htp->ntp)
709 htp = remmach(htp);
731 struct hosttbl *htp;
738 htp = addmach(msg->tsp_name, &from,fromnet);
739 htp->seq = msg->tsp_seq;
755 answer = acksend(&to, &htp->addr,
756 htp->name, TSP_ACK,
757 0, htp->noanswer);
759 htp->need_set = 0;
763 htp->name);
764 htp->noanswer = LOSTHOST;