--- channels/chan_sip.c.orig 2017-02-11 14:05:49.773681665 +0100 +++ channels/chan_sip.c 2017-02-11 14:08:09.864681549 +0100 @@ -31073,6 +31073,8 @@ firstpass = 0; } else { ast_format_cap_remove_by_type(peer->caps, AST_MEDIA_TYPE_UNKNOWN); + ast_rtp_dtls_cfg_free(&peer->dtls_cfg); + memset(&peer->dtls_cfg, 0, sizeof(peer->dtls_cfg)); } } else { if (!(peer = ao2_t_alloc(sizeof(*peer), sip_destroy_peer_fn, "allocate a peer struct"))) {