* Same as above, but with an additional mask. * XXX note this function is used only once. */
| 161 | * XXX note this function is used only once. |
| 162 | */ |
| 163 | static struct radix_node * |
| 164 | rn_search_m(void *v_arg, struct radix_node *head, void *m_arg) |
| 165 | { |
| 166 | struct radix_node *x; |
| 167 | caddr_t v = v_arg, m = m_arg; |
| 168 | |
| 169 | for (x = head; x->rn_bit >= 0;) { |
| 170 | if ((x->rn_bmask & m[x->rn_offset]) && |
| 171 | (x->rn_bmask & v[x->rn_offset])) |
| 172 | x = x->rn_right; |
| 173 | else |
| 174 | x = x->rn_left; |
| 175 | } |
| 176 | return (x); |
| 177 | } |
| 178 | |
| 179 | int |
| 180 | rn_refines(void *m_arg, void *n_arg) |