X-Git-Url: https://git.saurik.com/apple/xnu.git/blobdiff_plain/e5568f75972dfc723778653c11cb6b4dc825716a..c0fea4742e91338fffdcf79f86a7c1d5e2b97eb1:/bsd/netat/ddp_rtmp.c diff --git a/bsd/netat/ddp_rtmp.c b/bsd/netat/ddp_rtmp.c index c1b40b63e..023418dfc 100644 --- a/bsd/netat/ddp_rtmp.c +++ b/bsd/netat/ddp_rtmp.c @@ -174,10 +174,15 @@ void trackrouter(ifID, net, node) void ddp_age_router(deadrouter) register struct routerinfo *deadrouter; { - register at_ifaddr_t *ourrouter = deadrouter->ifID; - boolean_t funnel_state; + register at_ifaddr_t *ourrouter; - funnel_state = thread_funnel_set(network_flock, TRUE); + atalk_lock(); + + ourrouter = deadrouter->ifID; + if (ourrouter == NULL) { + atalk_unlock(); + return; + } dPrintf(D_M_RTMP, D_L_INFO, ("ddp_age_router called deadrouter=%d:%d\n", NODE(deadrouter), NET(deadrouter))); @@ -238,7 +243,7 @@ void ddp_age_router(deadrouter) } else bzero((caddr_t) deadrouter, sizeof(struct routerinfo)); - (void) thread_funnel_set(network_flock, FALSE); + atalk_unlock(); } /* ddp_age_router */