Bug 1559512: Make sure that we grab the first RTP packet when checking RTP extensions, because the mid extension is only used in the first several. r=jib

Differential Revision: https://phabricator.services.mozilla.com/D37884

--HG--
extra : moz-landing-system : lando
This commit is contained in:
Byron Campen [:bwc] 2019-07-12 21:36:16 +00:00
Родитель a2eaf3b1db
Коммит 88c34e7b3f
2 изменённых файлов: 9 добавлений и 5 удалений

Просмотреть файл

@ -33,14 +33,16 @@
);
}
const pc = SpecialPowers.wrap(test.pcRemote._pc);
const haveFirstPacket = getRtpPacket(pc);
test.chain.insertBefore('PC_REMOTE_WAIT_FOR_MEDIA_FLOW', [
async function PC_REMOTE_CHECK_RTP_HEADER_EXTS_AGAINST_SDP() {
const sdpExtmapIds = sdputils.findExtmapIds(test.originalAnswer.sdp);
let pc = SpecialPowers.wrap(test.pcRemote._pc);
let [level, type, sending, data] = await getRtpPacket(pc);
let extensions = ParseRtpPacket(data).header.extensions;
const [level, type, sending, data] = await haveFirstPacket;
const extensions = ParseRtpPacket(data).header.extensions;
// make sure we got the same number of rtp header extensions in
// the received packet as were negotiated in the sdp. Then

Просмотреть файл

@ -31,13 +31,15 @@
);
}
const pc = SpecialPowers.wrap(test.pcRemote._pc);
const haveFirstPacket = getRtpPacket(pc);
test.chain.insertBefore('PC_REMOTE_WAIT_FOR_MEDIA_FLOW', [
async function PC_REMOTE_CHECK_RTP_HEADER_EXTS_AGAINST_SDP() {
const sdpExtmapIds = sdputils.findExtmapIds(test.originalAnswer.sdp);
const pc = SpecialPowers.wrap(test.pcRemote._pc);
const [level, type, sending, data] = await getRtpPacket(pc);
const [level, type, sending, data] = await haveFirstPacket;
const packet = ParseRtpPacket(data);
const extIds = packet.header.extensions.map(e => `${e.id}`);
// make sure we got the same number of rtp header extensions in