MCPcopy Create free account
hub / github.com/F-Stack/f-stack / ng_pptpgre_shutdown

Function ng_pptpgre_shutdown

freebsd/netgraph/ng_pptpgre.c:560–576  ·  view source on GitHub ↗

* Destroy node */

Source from the content-addressed store, hash-verified

558 * Destroy node
559 */
560static int
561ng_pptpgre_shutdown(node_p node)
562{
563 const priv_p priv = NG_NODE_PRIVATE(node);
564
565 /* Reset node (stops timers) */
566 ng_pptpgre_reset(&priv->uppersess);
567
568 LIST_REMOVE(&priv->uppersess, sessions);
569 mtx_destroy(&priv->uppersess.mtx);
570
571 free(priv, M_NETGRAPH);
572
573 /* Decrement ref count */
574 NG_NODE_UNREF(node);
575 return (0);
576}
577
578/*************************************************************************
579 TRANSMIT AND RECEIVE FUNCTIONS

Callers

nothing calls this directly

Calls 2

ng_pptpgre_resetFunction · 0.85
freeFunction · 0.50

Tested by

no test coverage detected