static void session_destructor(void *arg) { struct menc_sess *st = arg; if (st->zrtp_session) zrtp_session_down(st->zrtp_session); }
static void session_destructor(void *arg) { struct menc_sess *st = arg; tmr_cancel(&st->abort_timer); if (st->zrtp_session) zrtp_session_down(st->zrtp_session); }
zrtp_status_t zrtp_test_session_destroy(zrtp_test_id_t id) { zrtp_test_session_t *session = zrtp_test_session_by_id(id); if (session) { /* NOTE: we don't release session slots here due to nature of testing * engine: test configuration constructed from scratch for every single test. */ zrtp_session_down(session->zrtp); } return zrtp_status_ok; }
void AmZRTPSessionState::freeSession() { if (NULL == zrtp_session) return; zrtp_session_down(zrtp_session); // // save zrtp cache // zrtp_cache_mut.lock(); // if (!((++zrtp_cache_save_cntr) % ZRTP_CACHE_SAVE_INTERVAL)) { // if (zrtp_cache_user_down() != zrtp_status_ok) { // ERROR("while writing ZRTP cache.\n"); // } // } // zrtp_cache_mut.unlock(); }