! ! Put multiple instructions into a block when iterating; unbreaks ! NET_RT_DUMP. ! This was broken in r193232 (save your time - my bug, my fix). ! ! PR: kern/137700 ! Reported by: Larry Baird (lab gta.com) ! Tested by: Larry Baird (lab gta.com) ! Reviewed by: zec, lstewart, qing ! Approved by: ! Index: sys/net/rtsock.c =================================================================== --- sys/net/rtsock.c (revision 196050) +++ sys/net/rtsock.c (working copy) @@ -1466,29 +1466,30 @@ sysctl_rtsock(SYSCTL_HANDLER_ARGS) (w.w_arg == 0 || w.w_arg & RTF_LLINFO)) { if (af != 0) error = lltable_sysctl_dumparp(af, w.w_req); else error = EINVAL; break; } /* * take care of routing entries */ - for (error = 0; error == 0 && i <= lim; i++) + for (error = 0; error == 0 && i <= lim; i++) { rnh = rt_tables_get_rnh(req->td->td_proc->p_fibnum, i); if (rnh != NULL) { RADIX_NODE_HEAD_LOCK(rnh); error = rnh->rnh_walktree(rnh, sysctl_dumpentry, &w); RADIX_NODE_HEAD_UNLOCK(rnh); } else if (af != 0) error = EAFNOSUPPORT; + } break; case NET_RT_IFLIST: error = sysctl_iflist(af, &w); break; case NET_RT_IFMALIST: error = sysctl_ifmalist(af, &w); break; }