@@ -899,6 +900,7 @@ rtable_mpath_reprio(unsigned int rtablei KERNEL_ASSERT_LOCKED(); + rtref(rt); /* keep rt alive in between remove and add */ SRPL_REMOVE_LOCKED(&rt_rc, &an->an_rtlist, rt, rtentry, rt_next); rt->rt_priority = prio; @@ -931,6 +933,7 @@ rtable_mpath_reprio(unsigned int rtablei } else { SRPL_INSERT_HEAD_LOCKED(&rt_rc, &an->an_rtlist, rt, rt_next); } + rtfree(rt); return (0); }