kevent: annotate unused stack local

This commit is contained in:
mmacy 2018-05-19 05:06:18 +00:00
parent c78ee89370
commit 56410d49b1

View File

@ -751,14 +751,12 @@ static void
filt_timerdetach(struct knote *kn)
{
struct kq_timer_cb_data *kc;
#ifdef INVARIANTS
unsigned int old;
#endif
unsigned int old __unused;
kc = kn->kn_ptr.p_v;
callout_drain(&kc->c);
free(kc, M_KQUEUE);
DBGSET(old, atomic_fetchadd_int(&kq_ncallouts, -1));
old = atomic_fetchadd_int(&kq_ncallouts, -1);
KASSERT(old > 0, ("Number of callouts cannot become negative"));
kn->kn_status |= KN_DETACHED; /* knlist_remove sets it */
}