MT#55283 retain codec tracker status for answers

In case of repeated answers without additional offer in between, we
shouldn't reset the codec tracker status at the end of the codec answer
routine, so that we end up with the same state during the next answer.

Change-Id: I54f6136cc5684473553b4862c13ea9f4a3dcfe99
pull/1772/head
Richard Fuchs 2 years ago
parent 8a3ddda53a
commit ed635a6460

@ -4631,6 +4631,13 @@ static struct codec_tracker *codec_tracker_init(void) {
return NULL;
#endif
}
static void codec_tracker_move(struct codec_tracker **dst, struct codec_tracker **src) {
#ifdef WITH_TRANSCODING
codec_tracker_destroy(dst);
*dst = *src;
*src = NULL;
#endif
}
static void codec_touched_real(struct codec_store *cs, struct rtp_payload_type *pt) {
#ifdef WITH_TRANSCODING
if (pt->codec_def && pt->codec_def->supplemental)
@ -5528,6 +5535,7 @@ void codec_store_answer(struct codec_store *dst, struct codec_store *src, sdp_ng
}
out:
codec_tracker_move(&dst->tracker, &orig_dst.tracker);
codec_store_cleanup(&orig_dst);
}

Loading…
Cancel
Save