Lines Matching refs:ws

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