MFC: Fix memory leak.

This commit is contained in:
ru 2005-12-09 07:13:06 +00:00
parent 90a9ef87c4
commit 9dbd13db82

View File

@ -219,6 +219,7 @@ static int
ngh_disconnect(hook_p hook)
{
FREE(NG_HOOK_PRIVATE(hook), M_NETGRAPH);
NG_HOOK_SET_PRIVATE(hook, NULL);
if (NG_NODE_NUMHOOKS(NG_HOOK_NODE(hook)) == 0)
ng_rmnode_self(NG_HOOK_NODE(hook));