static void lis_on_destroy(void *arg)
{
    struct tls_listener *listener = (struct tls_listener*)arg;

    if (listener->cert) {
	pj_ssl_cert_wipe_keys(listener->cert);
	listener->cert = NULL;
    }

    if (listener->factory.lock) {
	pj_lock_destroy(listener->factory.lock);
	listener->factory.lock = NULL;
    }

    if (listener->factory.pool) {
	PJ_LOG(4,(listener->factory.obj_name,  "SIP TLS transport destroyed"));
	pj_pool_secure_release(&listener->factory.pool);
    }
}
static void lis_on_destroy(void *arg)
{
    struct tls_listener *listener = (struct tls_listener*)arg;

    if (listener->cert) {
	pj_ssl_cert_wipe_keys(listener->cert);
	listener->cert = NULL;
    }

    if (listener->factory.lock) {
	pj_lock_destroy(listener->factory.lock);
	listener->factory.lock = NULL;
    }

    if (listener->factory.pool) {
	PJ_LOG(4,(listener->factory.obj_name,  "SIP TLS transport destroyed"));
	pj_pool_secure_release(&listener->factory.pool);
    }
}