/** * rgaFree * * * */ void rgaFree( rgaRing_t *ring) { size_t UNUSED(base_sz); base_sz = ring->elt_sz * ring->cap; #if YAF_RING_THREAD /* free conditions and mutex if present */ if (ring->cnd_zero) { g_cond_free(ring->cnd_zero); } if (ring->cnd_full) { g_cond_free(ring->cnd_full); } if (ring->mtx) { g_mutex_free(ring->mtx); } #endif /* free buffer */ yg_slice_free1(base_sz, ring->base); /* free structure */ yg_slice_free(rgaRing_t, ring); }
/** * flowFree * * * @param flow pointer to the flow structure with the context information * * */ void ypFlowFree( void *yfHookContext, yfFlow_t *flow) { ypDHCPFlowCtx_t *flowContext = (ypDHCPFlowCtx_t *)yfHookContext; if (NULL == flowContext) { return; } yg_slice_free1(sizeof(ypDHCPFlowCtx_t), flowContext); /* the other half of the slab allocator */ /* free (flowContext); */ return; }