Bug #2549 ยป netgraph7-nullify-apply-after-callback.patch
sys/netgraph7/netgraph/ng_base.c | ||
---|---|---|
if (refcount_release(&item->apply->refs)) {
|
||
(*item->apply->apply)(item->apply->context,
|
||
item->apply->error);
|
||
item->apply = NULL;
|
||
}
|
||
}
|
||
... | ... | |
if (apply != NULL) {
|
||
if (depth == 1 && error != 0)
|
||
apply->error = error;
|
||
if (refcount_release(&apply->refs))
|
||
if (refcount_release(&apply->refs)) {
|
||
(*apply->apply)(apply->context, apply->error);
|
||
item->apply = NULL;
|
||
}
|
||
}
|
||
return (error);
|