diff --git a/daemon/codec.c b/daemon/codec.c index 170715b7f..4b9eaf78b 100644 --- a/daemon/codec.c +++ b/daemon/codec.c @@ -3416,8 +3416,6 @@ void codec_tracker_finish(struct call_media *media, struct call_media *other_med } struct codec_handler *existing_handler = existing_pt ? codec_handler_get(media, existing_pt->payload_type) : NULL; - __rtp_payload_type_add_recv(media, pt, 1); - if (existing_pt && existing_handler) { // since this happens after we ran through the codec matchup, we must create the appropriate handler here struct codec_handler *handler = __get_pt_handler(media, pt); @@ -3425,6 +3423,7 @@ void codec_tracker_finish(struct call_media *media, struct call_media *other_med __make_transcoder(handler, &existing_handler->dest_pt, NULL, existing_handler->dtmf_payload_type, 0); } + __rtp_payload_type_add_recv(media, pt, 1); g_free(pt_s); }