Language: C
Label: safe
CWE: CWE-416 \u2014 Use After Free
Referencing memory after it has been freed can cause a program to crash, use unexpected values, or execute code.

Code:
static pj_status_t transport_destroy(pjmedia_transport *tp)
{
    /* Sanity check */
    PJ_ASSERT_RETURN(tp, PJ_EINVAL);

    pj_grp_lock_dec_ref(tp->grp_lock);

    return PJ_SUCCESS;
}