Lines Matching defs:ws

71 } ws;
357 naddr_ntoa(ws.to.sin_addr.s_addr));
362 if (ws.a != NULL && ws.a->type == RIP_AUTH_MD5)
363 end_md5_auth(wb, ws.a);
364 if (output(wb->type, &ws.to, ws.ifp, wb->buf,
365 ((char *)wb->n - (char *)wb->buf)) < 0 && ws.ifp != NULL)
366 if_sick(ws.ifp, _B_FALSE);
367 ws.npackets++;
371 clr_ws_buf(wb, ws.a);
390 if (ag->ag_seqno < update_seqno && (ws.state & WS_ST_FLASH))
396 (ws.state & WS_ST_TO_ON_NET) ? ws.ifp : NULL);
407 if ((ws.state & WS_ST_RIP2_ALL) ||
428 if (dstcount > ws.gen_limit) {
437 naddr_ntoa(ws.to.sin_addr.s_addr),
443 ws.gen_limit -= dstcount;
466 if (ws.state & WS_ST_RIP2_ALL) {
468 ((ws.state & WS_ST_QUERY) ||
469 (ag->ag_nhop != ws.ifp->int_addr &&
470 on_net(ag->ag_nhop, ws.ifp->int_net,
471 ws.ifp->int_mask)) &&
526 if (!should_supply(NULL) && !(ws.state & WS_ST_QUERY) &&
535 if (dst == RIP_DEFAULT && (ws.state & WS_ST_DEFAULT))
544 if (on_net(ws.to.sin_addr.s_addr,
554 if (ws.state & WS_ST_RIP2_ALL)
561 if (on_net(ws.to.sin_addr.s_addr,
597 if ((ws.state & WS_ST_AG) && ((RT->rt_state & RS_SUBNET) ||
598 (ws.state & WS_ST_SUPER_AG)))
610 on_net(dst, ws.to_net, ws.to_mask))
619 if ((ws.state & WS_ST_AG) && (ws.state & WS_ST_RIP2_ALL))
627 if ((RT->rt_state & RS_SUBNET) && !(ws.state & WS_ST_RIP2_ALL) &&
628 !on_net(dst, ws.to_std_net, ws.to_std_mask))
649 if (ws.ifp != NULL && !(ws.state & WS_ST_QUERY) &&
650 (ws.state & WS_ST_TO_ON_NET) && (!(RT->rt_state & RS_IF) ||
651 (ws.ifp->int_if_flags & IFF_POINTOPOINT))) {
654 if (rts->rts_metric > metric || rts->rts_ifp != ws.ifp)
697 pref = RT->rt_poison_metric + ws.metric;
698 metric += ws.metric;
707 if ((RT->rt_state & RS_STATIC) && (ws.ifp == RT->rt_ifp))
718 if (!(ws.state & WS_ST_QUERY) && (pref >= HOPCNT_INFINITY ||
752 ws.state = 0;
753 ws.gen_limit = WS_GEN_LIMIT_MAX;
755 ws.to = *dst;
756 ws.to_std_mask = std_mask(ws.to.sin_addr.s_addr);
757 ws.to_std_net = ntohl(ws.to.sin_addr.s_addr) & ws.to_std_mask;
760 ws.to_mask = ifp->int_mask;
761 ws.to_net = ifp->int_net;
762 if (on_net(ws.to.sin_addr.s_addr, ws.to_net, ws.to_mask) ||
764 ws.state |= WS_ST_TO_ON_NET;
767 ws.to_mask = ripv1_mask_net(ws.to.sin_addr.s_addr, NULL);
768 ws.to_net = ntohl(ws.to.sin_addr.s_addr) & ws.to_mask;
776 ws.npackets = 0;
778 ws.state |= WS_ST_FLASH;
780 ws.ifp = ifp;
788 ws.metric = 1;
802 ws.state |= WS_ST_QUERY;
818 ws.state |= WS_ST_RIP2_ALL;
819 if ((ws.state & WS_ST_QUERY) || !(ws.state & WS_ST_TO_ON_NET)) {
820 ws.state |= (WS_ST_AG | WS_ST_SUPER_AG);
822 ws.state |= WS_ST_AG;
825 ws.state |= WS_ST_SUPER_AG;
829 ws.a = find_auth(ifp);
830 if (!passwd_ok && ws.a != NULL && ws.a->type == RIP_AUTH_PW)
831 ws.a = NULL;
832 if (ws.a != NULL && (ulong_t)ws.a->end < (ulong_t)clk.tv_sec &&
833 !ws.a->warnedflag) {
840 naddr_ntoa(ws.to.sin_addr.s_addr));
841 ws.a->warnedflag = 1;
844 ws.a = NULL;
847 clr_ws_buf(&v12buf, ws.a);
848 clr_ws_buf(&v2buf, ws.a);
856 rt->rt_metric+ws.metric >= def_metric) {
857 ws.state |= WS_ST_DEFAULT;
861 def_metric = rt->rt_metric+ws.metric;
869 if ((ws.state & WS_ST_RIP2_ALL) &&
898 if (ws.npackets == 0 && (ws.state & WS_ST_QUERY)) {
900 if (ws.npackets == 0)