In ng_netflow_disconnect() check whether we are working with "iface"
or with "out" hook, and clear the right pointer. Reported by: Vitaliy Ovsyannikov <V.Ovsyannikov kr.ru>
This commit is contained in:
parent
4992df3ead
commit
747cdba40e
@ -614,8 +614,12 @@ ng_netflow_disconnect(hook_p hook)
|
||||
priv_p priv = NG_NODE_PRIVATE(node);
|
||||
iface_p iface = NG_HOOK_PRIVATE(hook);
|
||||
|
||||
if (iface != NULL)
|
||||
iface->hook = NULL;
|
||||
if (iface != NULL) {
|
||||
if (iface->hook == hook)
|
||||
iface->hook = NULL;
|
||||
if (iface->out == hook)
|
||||
iface->out = NULL;
|
||||
}
|
||||
|
||||
/* if export hook disconnected stop running expire(). */
|
||||
if (hook == priv->export) {
|
||||
|
Loading…
Reference in New Issue
Block a user